Title: Get access level name by code
Last modified: January 13, 2023

---

# Get access level name by code

 *  Resolved [sebastiansaravia](https://wordpress.org/support/users/sebastiansaravia/)
 * (@sebastiansaravia)
 * [3 years, 4 months ago](https://wordpress.org/support/topic/get-access-level-name-by-code/)
 * I’m trying to get the access level name of a user logged into my site but I’m
   not getting it.
   I checked the plugin documentation but it was very confusing 
   and I couldn’t find what I was looking for. Literally what I need is:
 * Variable(string) = function that returns the name of the access level of the 
   logged in user
 * Could you help me?
 * The page I need help with: _[[log in](https://login.wordpress.org/?redirect_to=https%3A%2F%2Fwordpress.org%2Fsupport%2Ftopic%2Fget-access-level-name-by-code%2F%3Foutput_format%3Dmd&locale=en_US)
   to see the link]_

Viewing 1 replies (of 1 total)

 *  Plugin Author [Joachim Jensen](https://wordpress.org/support/users/intoxstudio/)
 * (@intoxstudio)
 * [3 years, 4 months ago](https://wordpress.org/support/topic/get-access-level-name-by-code/#post-16383656)
 * While there is currently no way to get this via the RUA API, you can do it via
   shortcode like so:
 *     ```wp-block-code
       echo do_shortcode('[rua-user-levels id="'.$user_id.'"');
       ```
   

Viewing 1 replies (of 1 total)

The topic ‘Get access level name by code’ is closed to new replies.

 * ![](https://ps.w.org/restrict-user-access/assets/icon-256x256.png?rev=1815922)
 * [Restrict User Access - Ultimate Membership & Content Protection](https://wordpress.org/plugins/restrict-user-access/)
 * [Frequently Asked Questions](https://wordpress.org/plugins/restrict-user-access/#faq)
 * [Support Threads](https://wordpress.org/support/plugin/restrict-user-access/)
 * [Active Topics](https://wordpress.org/support/plugin/restrict-user-access/active/)
 * [Unresolved Topics](https://wordpress.org/support/plugin/restrict-user-access/unresolved/)
 * [Reviews](https://wordpress.org/support/plugin/restrict-user-access/reviews/)

## Tags

 * [code](https://wordpress.org/support/topic-tag/code/)

 * 1 reply
 * 2 participants
 * Last reply from: [Joachim Jensen](https://wordpress.org/support/users/intoxstudio/)
 * Last activity: [3 years, 4 months ago](https://wordpress.org/support/topic/get-access-level-name-by-code/#post-16383656)
 * Status: resolved