Skip to content

Introducing Private File Locker for HubSpot Files

Published: 5 February, 2024

Restrict file access to users logged in to HubSpot private pages

If you're using HubSpot's CRM to deliver content that users need to log in to access, you've probably noticed a major drawback when it comes to files loaded in HubSpot.

The links to those files are still publicly accessible, even though the pages you've linked them are not.

HubSpot's file manager offers three flavors of files.

Public means search engines can, and eventually will, index it so people searching will find it. Anyone can access the link.

Public - no index triggers a setting that tells search engines they shouldn't index it (and they probably won't). Hiding a link from Google simply means people won't stumble across it, but if it's shared with them or accidentally made public, anyone can access it.

Private means the file is completely locked down, so that only people within your organization who have a login to your HubSpot account can get to it, through HubSpot. Authorized users can generate a 24-hour link for an individual file.

That leaves a big gap.

If you're gating content and asking for an email address in order to download material, you'd really like to make sure it can't be accessed any other way.

If you've built a customer or partner portal in HubSpot, you're using a password-protected page, or you're selling a downloadable product, protection and file security get really serious. 

Now, you have files that are strictly for an authorized audience — price lists or sales playbooks for reseller partners, software that only customers should be able to download, either after paying, or by logging into their account in a HubSpot-native portal.

In the words of a VP of marketing deploying AllianceHub for a software company's partner portal, "If someone can just grab a link and post it publicly (like partner pricing) then that's really bad."

He was right. We needed a solution.

Introducing Private File Locker

Private File Locker is a small but mighty module that generates a time-limited encrypted link to a HubSpot private file. You can use it on your website pages including private pages, landing pages, blog posts and anywhere else you can add a HubSpot module.

Here's how it works:

  • Load your files to HubSpot's file system and set their visibility to private.
  • Add the Private File Locker module to the HubSpot page. Tell it the ID of the file to create a link for, and the text for the link.

Adding private file locker to a page


Whenever the page loads, an individual encrypted Locker Link is generated and the countdown begins. Once the time expires, the file is no longer available at that link.A Locker Link generated by Private File Locker

We've set the default duration to 15 minutes but you can change it to whatever you like. Getting a new Locker Link is as easy as refreshing the page and every Locker Link shows exactly when it's going to expire, in the user's local time.

It's magic in conjunction with HubSpot private pages, which is what we use for AllianceHub, since it can effectively restrict file access to users logged in to your AllianceHub partner portal. Your private files stay in HubSpot's secure environment, and time-restricted links enhance protection against unauthorized access.

Private File Locker is included with AllianceHub Pro and AllianceHub Extend, and will be available as a standalone HubSpot module.

You can see Private File Locker in action by taking the AllianceHub tour and checking out the sales resources.

Take the AllianceHub tour

Take a tour of AllianceHub

See how you can streamline your channel partner approach with a partner portal that lives inside HubSpot, right next to your marketing, sales and service tools.

Start