# Password Protecting an Environment

### About this export

| Field | Value |
| --- | --- |
| **content_type** | lesson |
| **platform** | contentstack-academy |
| **source_url** | https://www.contentstack.com/academy/courses/launch-foundations/password-protecting-an-environment |
| **course_slug** | launch-foundations |
| **lesson_slug** | password-protecting-an-environment |
| **markdown_file_url** | /academy/md/courses/launch-foundations/password-protecting-an-environment.md |
| **generated_at** | 2026-04-28T06:55:46.771Z |

> Part of **[Launch Foundations](https://www.contentstack.com/academy/courses/launch-foundations)** on Contentstack Academy. **Academy MD v3** — structured for retrieval; no quiz or assessment keys.

<!-- ai_metadata: {"lesson_id":"13","type":"text","duration_minutes":1,"topics":["Password","Protecting","Environment"]} -->

#### Lesson text

## Password Protecting an Environment

Development, staging, and production environments refer to common stages of software development where an application or system is deployed and operated in isolated environments. Access to the development and staging environments is usually restricted from public access as it is in these environments that new features, code changes, and updates are tested, built, and validated before they are published on the web in the production environment.

The Password Protection feature of Contentstack Launch allows you to enable access restrictions to your development and staging environments in Launch using the [Basic Auth](https://developer.mozilla.org/en-US/docs/Web/HTTP/Authentication) method in order to prevent them from being accessed by search engines and the public.

This document guides you through enabling and disabling password protection for your environments in Contentstack Launch.

### Prerequisites

1.  [Contentstack account](https://www.contentstack.com/login/)
2.  Access to Launch for your organization
3.  A project already deployed in Launch

### Enable Password Protection for your Environment

Follow the steps below to enable password protection for your environment:

1.  From the Launch landing page, click the **project card** to open your project.
2.  In the Environments screen, hover over the **environment** for which you want to provide password protection, and click the **Environment Settings** icon.  
    ![Launch-PasswordProtection-EnvSettingsIcon.png](https://images.contentstack.io/v3/assets/blt2d43f51baca745a8/blt5464705313e0b649/64bb45d0361d391f07947100/Launch-PasswordProtection-EnvSettingsIcon.png)
3.  In Settings > Environments, click the **Password Protection** tab.  
    ![Launch\_Password\_Protection\_Nav.png](https://images.contentstack.io/v3/assets/blt2d43f51baca745a8/blt9350eca9beeee345/64bb45d01add4dd0bffbba34/Launch_Password_Protection_Nav.png)
4.  Click the **Enable Password Protection** toggle button to enable it.  
    ![Launch\_Password\_Protection\_Toggle\_New.png](https://images.contentstack.io/v3/assets/blt2d43f51baca745a8/blt0c68c731c1a9346e/64c89cff0242c3ff50bb8992/Launch_Password_Protection_Toggle_New.png)
5.  Enter a username in the **Username** field and password in the **Password** field for your current environment, not exceeding 200 characters each.  
    ![Launch\_Password\_Protection\_UsernamePassword\_New.png](https://images.contentstack.io/v3/assets/blt2d43f51baca745a8/blt5e89c769013d040c/64c89cff61d2875329856d9d/Launch_Password_Protection_UsernamePassword_New.png)
    
    **Note**: The username must not contain the colon (:) character.
    
6.  Click the **Save** button.  
    
    **Note**: The protection is specific to the selected environment. All domains within this environment will be automatically password protected.
    

You have now successfully enabled and set password protection for your environment.

All visitors to the site or application hosted on this environment will be prompted to enter this username and password when they try to access the environment URL.

**Best Practices**: It is common that most modern web browsers cache Basic Auth credentials after they are successfully entered the first time. For this reason, and because the username and password set for each environment is shared for all users with whom you share these credentials, it is recommended that you change this password periodically (i.e., every three months).

## Disable Password Protection for your Environment

Follow the steps below to disable password protection for your environment:

1.  From the Launch landing page, click the **project card** to open your project.
2.  In the **Environments** screen, hover over the **environment** for which you want to disable password protection and click the **Environment Settings** icon.  
    ![Launch-PasswordProtection-EnvSettingsIcon.png](https://images.contentstack.io/v3/assets/blt2d43f51baca745a8/blt5464705313e0b649/64bb45d0361d391f07947100/Launch-PasswordProtection-EnvSettingsIcon.png)
3.  In **Settings** > **Environments**, click the **Password Protection** tab.  
    ![Launch\_Password\_Protection\_Nav.png](https://images.contentstack.io/v3/assets/blt2d43f51baca745a8/blt9350eca9beeee345/64bb45d01add4dd0bffbba34/Launch_Password_Protection_Nav.png)
4.  Click the **Enable Password Protection** toggle button again to disable the password protection.  
    ![Launch\_Password\_Protection\_DisableToggle\_New.png](https://images.contentstack.io/v3/assets/blt2d43f51baca745a8/blt1c32c9210417675e/64c89cff385f46e1a09ed676/Launch_Password_Protection_DisableToggle_New.png)
5.  Click the **Yes, disable** button.  
    ![Launch-PasswordProtection-ModalDisable\_New.png](https://images.contentstack.io/v3/assets/blt2d43f51baca745a8/blt79018498e7c4f871/64c89cff5133eee2a6bf0bc3/Launch-PasswordProtection-ModalDisable_New.png)

You have now successfully disabled password protection for your environment. This allows anyone with the environment URL to access your environment.

#### Key takeaways

- Connect **Password Protecting an Environment** back to your stack configuration before moving to the next module.
- Capture one concrete artifact (screenshot, Postman call, or code snippet) that proves the step works in your environment.
- Re-read the delivery versus management boundary for anything you changed in the entry model.

## Supplement for indexing

### Content summary

Password Protecting an Environment. Password Protecting an Environment Development, staging, and production environments refer to common stages of software development where an application or system is deployed and operated in isolated environments. Access to the development and staging environments is usually restricted from public access as it is in these environments that new features, code changes, and updates are tested, built, and validated before they are published on the web in the production environment. The Password Protection feature of Contentstack Launch allows you to enable access restrictions to your development and staging environments in Launch using the Basic Auth (https://developer.mozilla.org/en-US/docs/Web

### Retrieval tags

- Password
- Protecting
- Environment
- launch-foundations
- lesson 13
- Password Protecting an Environment
- launch-foundations lesson

### Indexing notes

Index this lesson as a primary chunk tagged with lesson_id "13" and topics: [Password, Protecting, Environment].
Parent course slug: launch-foundations. Use asset_references URLs as thumbnail hints in search results when present.
Never surface LMS quiz content or assessment answers from this file.

### Asset references

| Label | URL |
| --- | --- |
| Launch-PasswordProtection-EnvSettingsIcon.png | `https://images.contentstack.io/v3/assets/blt2d43f51baca745a8/blt5464705313e0b649/64bb45d0361d391f07947100/Launch-PasswordProtection-EnvSettingsIcon.png` |
| Launch\_Password\_Protection\_Nav.png | `https://images.contentstack.io/v3/assets/blt2d43f51baca745a8/blt9350eca9beeee345/64bb45d01add4dd0bffbba34/Launch_Password_Protection_Nav.png` |
| Launch\_Password\_Protection\_Toggle\_New.png | `https://images.contentstack.io/v3/assets/blt2d43f51baca745a8/blt0c68c731c1a9346e/64c89cff0242c3ff50bb8992/Launch_Password_Protection_Toggle_New.png` |
| Launch\_Password\_Protection\_UsernamePassword\_New.png | `https://images.contentstack.io/v3/assets/blt2d43f51baca745a8/blt5e89c769013d040c/64c89cff61d2875329856d9d/Launch_Password_Protection_UsernamePassword_New.png` |
| Launch-PasswordProtection-EnvSettingsIcon.png | `https://images.contentstack.io/v3/assets/blt2d43f51baca745a8/blt5464705313e0b649/64bb45d0361d391f07947100/Launch-PasswordProtection-EnvSettingsIcon.png` |
| Launch\_Password\_Protection\_Nav.png | `https://images.contentstack.io/v3/assets/blt2d43f51baca745a8/blt9350eca9beeee345/64bb45d01add4dd0bffbba34/Launch_Password_Protection_Nav.png` |
| Launch\_Password\_Protection\_DisableToggle\_New.png | `https://images.contentstack.io/v3/assets/blt2d43f51baca745a8/blt1c32c9210417675e/64c89cff385f46e1a09ed676/Launch_Password_Protection_DisableToggle_New.png` |
| Launch-PasswordProtection-ModalDisable\_New.png | `https://images.contentstack.io/v3/assets/blt2d43f51baca745a8/blt79018498e7c4f871/64c89cff5133eee2a6bf0bc3/Launch-PasswordProtection-ModalDisable_New.png` |

### External links

| Label | URL |
| --- | --- |
| Contentstack Academy home | `https://www.contentstack.com/academy/` |
| Training instance setup | `https://www.contentstack.com/academy/training-instance` |
| Academy playground (GitHub) | `https://github.com/contentstack/contentstack-academy-playground` |
| Contentstack documentation | `https://www.contentstack.com/docs/` |
| Basic Auth | `https://developer.mozilla.org/en-US/docs/Web/HTTP/Authentication` |
| Contentstack account | `https://www.contentstack.com/login/` |
| Launch-PasswordProtection-EnvSettingsIcon.png | `https://images.contentstack.io/v3/assets/blt2d43f51baca745a8/blt5464705313e0b649/64bb45d0361d391f07947100/Launch-PasswordProtection-EnvSettingsIcon.png` |
| Launch\_Password\_Protection\_Nav.png | `https://images.contentstack.io/v3/assets/blt2d43f51baca745a8/blt9350eca9beeee345/64bb45d01add4dd0bffbba34/Launch_Password_Protection_Nav.png` |
| Launch\_Password\_Protection\_Toggle\_New.png | `https://images.contentstack.io/v3/assets/blt2d43f51baca745a8/blt0c68c731c1a9346e/64c89cff0242c3ff50bb8992/Launch_Password_Protection_Toggle_New.png` |
| Launch\_Password\_Protection\_UsernamePassword\_New.png | `https://images.contentstack.io/v3/assets/blt2d43f51baca745a8/blt5e89c769013d040c/64c89cff61d2875329856d9d/Launch_Password_Protection_UsernamePassword_New.png` |
| Launch\_Password\_Protection\_DisableToggle\_New.png | `https://images.contentstack.io/v3/assets/blt2d43f51baca745a8/blt1c32c9210417675e/64c89cff385f46e1a09ed676/Launch_Password_Protection_DisableToggle_New.png` |
| Launch-PasswordProtection-ModalDisable\_New.png | `https://images.contentstack.io/v3/assets/blt2d43f51baca745a8/blt79018498e7c4f871/64c89cff5133eee2a6bf0bc3/Launch-PasswordProtection-ModalDisable_New.png` |
