The LifterLMS Database Explained: Post Types, Meta and Custom Tables
A developer’s map of the LifterLMS database: which post types hold courses, orders and certificates, where enrollments and progress live, what each…
Read articleLifterLMS shortcodes let you place course grids, progress bars, checkout forms, login forms and conditional content anywhere WordPress accepts a shortcode: a page, a widget, a page builder module or a PHP template. Blocks cover most of the same ground in the block editor, but shortcodes still matter for page builders, classic themes, emails of your own and custom templates.
This reference lists every shortcode registered by the LifterLMS 10.3 core plugin, with the attributes it actually accepts and their defaults, taken from the plugin source. Add-ons register more of their own; those are noted at the end. Developers will find a section on calling shortcodes in code and writing their own.
A few rules apply to all of them:
post=123). Access plan IDs are shown in the plan's header in the course or membership editor.yes/no or 1/0 depending on the shortcode; the tables say which.In the block editor, prefer the LifterLMS blocks: they have the same output, a settings panel instead of attributes, and visibility controls for enrolled or non-enrolled visitors. Use shortcodes in page builders without a native LifterLMS module, classic widgets, PHP templates, and anywhere you need conditional content inside a text field. Our LifterLMS blocks guide maps each block to its shortcode.
Outputs a grid of course tiles.
| Attribute | Default | Notes |
|---|---|---|
| id | empty | Comma-separated course IDs to show only those courses |
| category | empty | A course category slug |
| mine | no | any, enrolled, expired or cancelled limits the grid to the current student's courses with that status |
| hidden | yes | no excludes courses whose catalog visibility is Hidden |
| posts_per_page | -1 | Number of courses; -1 shows all |
| order / orderby | ASC / title | Standard WordPress ordering values |
| post_status | publish | Rarely changed |
Example, a "My active courses" page: [lifterlms_courses mine="enrolled" orderby="date" order="DESC"]. If the student has no matching courses, LifterLMS prints a message instead of the whole catalog. Our course catalog guide covers catalog layout in depth.
The membership equivalent, with category (membership category slug), posts_per_page, order and orderby. Example: [lifterlms_memberships category="business" posts_per_page="6"].
A simpler course grid that accepts category, per_page, order and orderby. Prefer [lifterlms_courses] for new pages; it has more options.
All of these accept course_id and default to the current course, or the parent course when used on a lesson.
| Shortcode | Outputs | Extra attributes |
|---|---|---|
| [lifterlms_course_author] | Author name and avatar | avatar_size (48), bio (yes) |
| [lifterlms_course_instructors] | All listed instructors | none |
| [lifterlms_course_meta_info] | Length, difficulty, categories, tags and tracks | none |
| [lifterlms_course_syllabus] | The full syllabus with lock and completion status | none |
| [lifterlms_course_outline] | A compact outline | outline_type (full or current_section), collapse (0), toggles (0) |
| [lifterlms_course_prerequisites] | A notice listing unmet prerequisites | none |
| [lifterlms_course_reviews] | Reviews and the review form | none |
| [lifterlms_course_continue] | Progress bar plus continue button, enrolled students only | none |
| [lifterlms_course_continue_button] | Just the button: Get Started, Continue, or a "Course Complete" line | none |
Two older shortcodes work on the current course only and take no ID: [lifterlms_course_title] and [lifterlms_course_progress]. Add check_enrollment="1" to the progress shortcode so it prints nothing for visitors who are not enrolled.
Example, a collapsible outline of only the student's current section in a lesson sidebar: [lifterlms_course_outline outline_type="current_section" collapse="1" toggles="1"].
Prints a single stored course value. Attributes: id (current post), key, type (empty, date or price) and date_format. Keys ending in _date are treated as dates automatically. Examples:
[lifterlms_course_info key="length"] prints the Course Length field.[lifterlms_course_info key="start_date" date_format="j F Y"] prints the course start date.[lifterlms_course_info id="123" key="enrolled_students"] prints the stored enrolled-student count.[lifterlms_lesson_mark_complete] prints the Mark Complete button, or Take Quiz and assignment buttons when the lesson has them. Use it when a page builder template replaces the default lesson layout. Without it, students cannot complete the lesson.[lifterlms_lesson_navigation] prints previous and next lesson links.[lifterlms_favorites] lists the student's favourite lessons when Lesson Favorites is enabled under Courses settings. Attributes: orderby (updated_date), order (ASC) and limit.[lifterlms_pricing_table product="123"] shows the access plans of a course or membership. Without product it uses the current post. See our pricing table guide for layout tips.[lifterlms_access_plan_button id="456"] links straight to checkout for one access plan. Attributes: type (primary, secondary, action or danger), size (small or large), classes for your own CSS classes. Text between opening and closing tags replaces the button label: [lifterlms_access_plan_button id="456" size="large"]Join the spring cohort[/lifterlms_access_plan_button].[lifterlms_checkout] renders checkout and must sit on the page set as Checkout under LifterLMS > Settings > Checkout. You do not normally add it by hand.[lifterlms_my_account] is the student dashboard, placed on the page chosen as the dashboard page. Attributes: layout (columns or stacked) and login_redirect, the address a student is sent to after logging in from the dashboard page.[lifterlms_login] shows the login form anywhere. Attributes: layout (columns) and redirect (the current page). Example: [lifterlms_login layout="stacked" redirect="/dashboard/"]. Our guide to login pages and redirects explains the redirect order.[lifterlms_registration] shows the registration form you edit under LifterLMS forms. It is hidden from visitors who are already logged in.[lifterlms_my_achievements] shows the current student's achievements. Attributes: count, columns (5) and user_id.Shows its content only to users enrolled in the given courses or memberships, and an optional message to everyone else.
[lifterlms_hide_content id="123,456" relation="any" message="Join a course to see the bonus downloads."]
Bonus downloads go here.
[/lifterlms_hide_content]
id takes one or more course or membership IDs and defaults to the current post. relation is all (default: enrolled in every listed item) or any. The older membership attribute still works for one membership. This is page-level personalisation, not file security: a link revealed inside it can still be shared. For protecting files, see our guide to protecting course media files, and for whole pages, restricting pages and posts to members.
Prints a field from the current user's account, with a fallback. [llms-user first_name or="there"] prints "Hi there" style greetings for logged-out visitors. The key can be any user field or user meta key; passwords are blocked.
A link to a membership: [lifterlms_membership_link id="789"]Upgrade to Pro[/lifterlms_membership_link]. Without enclosed text it uses the membership title. It prints nothing if the membership is not published.
[lifterlms_membership_instructors] lists instructors on a membership page. [lifterlms_bbp_course_forums] lists bbPress forums linked to a course when the bbPress integration is enabled; see our bbPress course forums guide.
In a theme template or custom plugin, run a shortcode with do_shortcode():
echo do_shortcode( '[lifterlms_course_continue_button course_id="' . absint( $course_id ) . '"]' );
When you need something core does not offer, write your own shortcode on top of LifterLMS functions rather than editing core. This one prints the current student's progress percentage for any course as plain text, handy inside a sentence:
add_shortcode( 'llmsx_progress_text', 'llmsx_progress_text_shortcode' );
function llmsx_progress_text_shortcode( $atts ) {
$atts = shortcode_atts( array( 'course_id' => get_the_ID() ), $atts, 'llmsx_progress_text' );
$student = llms_get_student();
if ( ! $student || ! llms_is_user_enrolled( $student->get_id(), $atts['course_id'] ) ) {
return '';
}
return esc_html( round( $student->get_progress( absint( $atts['course_id'] ), 'course' ) ) . '%' );
}
Usage: You are [llmsx_progress_text course_id="123"] of the way through. Core shortcodes also expose filters: every tag registered through the older method can be renamed with {tag}_shortcode_tag, and the list of shortcode classes loaded passes through llms_load_shortcodes, documented on the LifterLMS developer hub.
Paid add-ons register their own shortcodes, for example [llms_pa_info] from Private Areas and [llms_sl_directory] from Social Learning. They only work while the add-on is active. LifterLMS keeps a shortcode list in its documentation as well.
course_id explicitly." into typographic quotes, which breaks attributes.In the course or membership editor, in the header of each access plan in the pricing section.
Yes. Use [lifterlms_hide_content] with a message for non-enrolled visitors, or block visibility settings in the block editor.
It still works as an alias of [lifterlms_courses] but is deprecated. Replace it.
Bookmark this page, and replace any hard-coded links to courses or checkout on your site with the matching shortcode or block so they stay correct when plans change.
If you need a shortcode that does not exist, such as a team progress table or a custom catalog filter, our LifterLMS plugin development service builds them as update-safe plugins. Describe what you want on the page and we will tell you whether a core shortcode already does it.
A developer’s map of the LifterLMS database: which post types hold courses, orders and certificates, where enrollments and progress live, what each…
Read article
A code walk-through for creating students and enrollments in LifterLMS from a CRM, sales tool or custom app: look up by email, create the account…
Read article
What LifterLMS 10.x registers with the WordPress Abilities API, how an AI agent can discover and run those abilities over REST or MCP, and the…
Read articleSkip the trial and error. Get specialist LifterLMS help and ship faster.