How to Hide LearnDash Course Materials from Unenrolled Users

By default, LearnDash course materials are displayed to everyone, both enrolled and unenrolled users. Many people would like course materials only available to those who are enrolled in the course.

There are two basic ways to handle this:

  1. You can use the following shortcodes that LearnDash provides to only show your materials to enrolled users.
  1. You can place your materials in the first lesson of the course, instead of the course itself. This will protect them automatically because a user can't access any course lessons unless they are enrolled.

We cover both options in this video, along with a few other tips to keep in mind.

There is a third option that doesn't use the LearnDash materials feature, but instead uses the block editor. This will place materials directly in your content area, and not use the separate "Materials" tab.

For this method, we'll be using the block editor and the "LearnDash Student" block. This block does the same thing as the shortcode above, just in block format. It's essentially a group that you can add other blocks to, and those blocks will only be visible to enrolled users.

View the video below:

You need to be a premium member to continue accessing this content.

Sign Up Today →

Dave Warfel

Dave Warfel

I've been working with LearnDash for over 3.5 years, and have developed 3 free & 2 premium plugins for WordPress' most popular LMS. Nothing brings me more joy than empowering others to take control of their online platform. I live, work & play in the beautiful mountains of Colorado. 🤸‍♂️👨‍💻🏃‍♂️🏔️

Forum Rules

Be Kind & Patient

We’re here to learn and/or help each other. Please don’t be mean, rude, or condescending. Treat all members the way you should be treating dogs and your elders—with the utmost love & respect.

External Links

✅ Other websites that add value, help solve problems & contribute to the discussion. ❌ Affiliate links are prohibited. (Site owners may use affiliate links to help support the site.)


✅ You may promote your own products/services if they are relevant to an existing discussion. You must disclose your relationship with the product(s).
❌ You may not create new posts simply to promote your products.

Non-LearnDash Topics

❌ General (free) Forum: Only LearnDash-specific topics are allowed.
✅ Premium Forums: You are allowed to post other questions tangentially related to LearnDash. Please use the appropriately named forum. If it doesn’t exist, use the “LearnDash Integrations” forum.

Our Right to Remove

We reserve the right to remove any content, at any time, for any reason. We can also merge one post with another. We will exercise caution when removing content and always try to provide an explanation.