Counting Named Users in RStudio Connect and RStudio Server Pro


You may have an RStudio license that requires you to report a peak number of annual named users. (Or you may just be curious about how many users are accessing your analytic tools). Learn how to count named users for RStudio Connect and RStudio Server Pro. 

Named Users in RStudio Connect

Most RStudio Connect installations consist of one or more servers that share a database of content and users. RStudio Connect admins can visit the Admin Dashboard's Metrics page to view a graph of "Active Users" over time. 

For RStudio license reporting, select "1 Year" for the graph duration, and then report the number of active users recorded in the dashboard.




In some scenarios, there may be separate RStudio Connect installations. For example, a consulting firm may have an RStudio Connect installation dedicated to each client. In this case, visit the dashboard for each unique RStudio Connect installation and total the number of "Active Users" in the past year. This method may double count some users, e.g. consultants that have accounts on different client servers. Normally, double counting will not affect your licensing tier. If you are concerned about double counting, you can dump user data with the usermanager list command and use R to identify the unique users over the last year.



The RStudio Connect People dashboard provides RStudio Connect administrators information about users such as the last time they were actively logged in as well as their license status. RStudio Connect admins can lock a user to prevent the user from counting against the license using the web dashboard or usermanager command


Named Users in RStudio Server Pro

If you have a named user license for RStudio Server Pro, it is critical that you enable the session audit log immediately upon installing RStudio Server Pro. 

To do so, follow these instructions:

    1. Edit /etc/rstudio/rserver.conf to include:    


    2. Restart RStudio Server Pro:

sudo rstudio-server stop; sudo rstudio-server start;

Ensure that session auditing is enabled for every RStudio Server Pro instance. When it is time to report named users, first copy the session audit log /var/lib/rstudio-server/audit/r-sessions/r-sessions.csv to a central directory for analysis. Copy the audit logs from each RStudio Server Pro instance.

Within the directory containing the audit logs, use R to identify the unique named users over the last year. Sample R code is below:


named_users <- map_df(list.files(".", "*\\.csv"), readr::read_csv) %>% 
  mutate(time = as_datetime(timestamp/1e3)) %>% 
  filter(time >= today() - dyears(1)) %>% 
  filter(type == " session_start") %>% 
  select(username) %>% 
  unique() %>% 
glue('Thanks for using RStudio! This server has had {named_users} named users since {today() - dyears(1)}.')

Please contact or if you need assistance calculating the number of named users.