How Media Guard Access Works: Roles, Groups, and Purchases
The three ways Media Guard decides who gets in
Every time someone tries to open a protected file, Media Guard runs a simple check: is this person allowed? You tell Media Guard what “allowed” means by choosing one (or more) of these access methods:
- WordPress Roles — built into every WordPress site. Free.
- Media Guard Groups — custom access groups you create yourself. Requires Pro.
- WooCommerce purchase — gate the file behind buying a product. Free.
You set all of these inside the shortcode on the page (or in the File Manager for Groups). No code needed.
1. WordPress Roles — the simplest choice
WordPress already gives every user a “role” — Administrator, Editor, Author, Contributor, or Subscriber. Most small sites just need Subscriber (a regular logged-in member).
Use roles when:
- You have a small site and just want “members only” content.
- Your membership plugin assigns a WordPress role automatically when someone signs up.
How it looks:
[mediaguard file="board-minutes.pdf" roles="subscriber"]
You can list multiple roles, separated by commas:
[mediaguard file="staff-handbook.pdf" roles="editor,author"]
2. Media Guard Groups — for more control (Pro)
Groups are custom access tiers that live inside Media Guard itself, separate from WordPress roles. They’re great when one user might belong to several different access levels — like “Bronze Members”, “Gold Members”, and “Course A Students” all at once.
Use groups when:
- You have multiple tiers or cohorts that don’t fit neatly into WordPress roles.
- You’re protecting course materials and want each course to have its own access list.
- You want to add a user to several access tiers without changing their WordPress role.
How it works (Pro): in Media Guard → File Manager, select one or more files, then use the Assign to Group… dropdown to put them in a group. Then on your page:
[mediaguard file="course-a-week-1.pdf" groups="course-a"]
3. WooCommerce purchase — sell access
If you sell digital products, you can tie a file to a WooCommerce product. Once a customer’s order is marked Completed, they get access. If you also use WooCommerce Subscriptions, access stays active for as long as the subscription is active.
See the WooCommerce guide for the full setup.
Which one should I pick?
| Your situation | Use this |
|---|---|
| Small site, “members only” PDFs | Roles (Subscriber) |
| Multiple courses, each with their own files | Groups (Pro) |
| Different membership tiers (Bronze / Gold / Platinum) | Groups (Pro) |
| Selling individual files or bundles | WooCommerce purchase |
| Already use a membership plugin that assigns a role | Roles |
Can I combine them?
Yes. You can mix roles and groups in the same shortcode. The user must match any of the listed criteria to get in:
[mediaguard file="report.pdf" roles="editor" groups="board-members"]
One thing to remember: admins always get in
Administrators bypass every access check. That’s by design — you need to be able to manage your own files. When you’re testing protection, always use an Incognito window or a separate non-admin test account.
Related Pro features
Ready to take this further with Media Guard Pro?
- Groups & Users — Build reusable groups and assign access in one click instead of editing every file.
- Access Log — See exactly which user opened which file, when, and from where.
- shortcode — Drop a personalized ‘your downloads’ page on any post or page.