---
title: 'Tutorial: How to Change the Web Session Timeout'
canonical: https://openvpn.net/as-docs/tutorials/tutorial--web-session-timeout/
product: Access Server Docs
description: With this tutorial, you can change the web session timeout for Access Server's web services.
---

# Tutorial: How to Change the Web Session Timeout

## Overview

When you authenticate to Access Server's Client Web UI (or client web service, CWS) or Admin Web UI (or admin web services, AWS), your session remains active for a set timeframe. You remain signed in while you're actively using the web page, but your session expires if you're inactive for 30 minutes.

You can follow this tutorial to adjust this default 30-minute setting.

## Prerequisites

- An installed Access Server.
- Console access and the ability to get root access.

## Step 1: Check the current setting

1. Sign in to the console and get root privileges.
2. Switch to the scripts directory:

   ```
   cd /usr/local/openvpn_as/scripts/
   ```
3. See the current setting:

   ```
   ./sacli ConfigQuery | grep -i "sa.session_expire"
   ```

   - If nothing displays, the **sa.session\_expire** configuration key uses the default value of 1800 seconds (30 minutes).

## Step 2: Change the web session expiration

1. Set the inactivity timeout to five minutes (300 seconds):

   ```
   ./sacli --key "sa.session_expire" --value "300" ConfigPut
   ./sacli start
   ```

   You set the **sa.session\_expire** configuration key to a value in seconds. So, for this example, it's 300 seconds, which is five minutes. Adjust your command to the number of seconds you desire for the session expiration.

## Optional: Reset to default value

1. Remove the key so it resets to its default of 30 minutes:

   ```
   ./sacli --key "sa.session_expire" ConfigDel
   ./sacli start
   ```

---

Prev: [Tutorial: Change the Web Service Forwarding Settings](https://openvpn.net/as-docs/tutorials/tutorial--web-services-forwarding.md)
Next: [Tutorial: Set the Interface and Ports for the Web Services](https://openvpn.net/as-docs/tutorials/tutorial--web-services-interface-and-ports.md)
Index: https://openvpn.net/as-docs/llms.txt
