# CLI command to update HTML universal login page

**URL:** <https://community.auth0.com/t/cli-command-to-update-html-universal-login-page/116261>\
**Category:** Get Help\
**Tags:** new-universal-login-experience, login-experience\
**Created:** [September 14, 2023, 7:56pm UTC](https://community.auth0.com/t/cli-command-to-update-html-universal-login-page/116261 "2023-09-14T19:56:23Z")\
**Posts on this page:** 9\
**Page:** 1

<div class="post-metadata">

**Author:** ![srajendran](https://upload.wikimedia.org/wikipedia/commons/thumb/7/7c/User_font_awesome.svg/768px-User_font_awesome.svg.png) [@srajendran](https://community.auth0.com/u/srajendran)\
**Post date:** [September 14, 2023, 7:56pm UTC](https://community.auth0.com/t/cli-command-to-update-html-universal-login-page/116261/1 "2023-09-14T19:56:23Z")

</div>

Hi,  
i would like to know if there is a CLI command to update HTML page in universal login page. I usually update the HTML file manually by copy and pasting the contents of login.html to branding-\>universal login-\> login-\>HTML and save it to see the changes. I am trying to see if i would be able to automate the process of updating this when a new code is pushed. Please let me know.  
Thanks,  
Suguna

---

<div class="post-metadata">

**Author:** ![rueben.tiow](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/rueben.tiow/32/11646_2.png) [@rueben.tiow](https://community.auth0.com/u/rueben.tiow)\
**Post date:** [September 14, 2023, 8:42pm UTC](https://community.auth0.com/t/cli-command-to-update-html-universal-login-page/116261/3 "2023-09-14T20:42:55Z")

</div>

Hi @srajendran,

You could use the Auth0 CLI to update your Universal Login page:

> **[auth0 universal-login templates](https://auth0.github.io/auth0-cli/auth0_universal-login_templates)**
>
> Build, manage and test your Auth0 integrations from the command line.

Or you could use the Management API to update the Universal Login page:  
[https://auth0.com/docs/api/management/v2/branding/put-universal-login](https://auth0.com/docs/api/management/v2/branding/put-universal-login)

Please let me know if you have any questions.

Thanks,  
Rueben

---

<div class="post-metadata">

**Author:** ![srajendran](https://upload.wikimedia.org/wikipedia/commons/thumb/7/7c/User_font_awesome.svg/768px-User_font_awesome.svg.png) [@srajendran](https://community.auth0.com/u/srajendran)\
**Post date:** [September 18, 2023, 2:14pm UTC](https://community.auth0.com/t/cli-command-to-update-html-universal-login-page/116261/4 "2023-09-18T14:14:33Z")

</div>

Could you provide me a exact CLI command if possible?

---

<div class="post-metadata">

**Author:** ![rueben.tiow](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/rueben.tiow/32/11646_2.png) [@rueben.tiow](https://community.auth0.com/u/rueben.tiow)\
**Post date:** [September 18, 2023, 3:40pm UTC](https://community.auth0.com/t/cli-command-to-update-html-universal-login-page/116261/5 "2023-09-18T15:40:19Z")

</div>

Hi @srajendran,

You can view the template by calling:  
`auth0 universal-login templates show`

And to update the template using:  
`auth0 universal-login templates update`

---

<div class="post-metadata">

**Author:** ![srajendran](https://upload.wikimedia.org/wikipedia/commons/thumb/7/7c/User_font_awesome.svg/768px-User_font_awesome.svg.png) [@srajendran](https://community.auth0.com/u/srajendran)\
**Post date:** [September 18, 2023, 8:15pm UTC](https://community.auth0.com/t/cli-command-to-update-html-universal-login-page/116261/6 "2023-09-18T20:15:23Z")

</div>

Hi @rueben.tiow , Thank you for your time in answering my questions. Does the CLI command shared by you be used for the custom html page which i wanted to update or it is used only for the default templates?

---

<div class="post-metadata">

**Author:** ![rueben.tiow](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/rueben.tiow/32/11646_2.png) [@rueben.tiow](https://community.auth0.com/u/rueben.tiow)\
**Post date:** [September 18, 2023, 9:49pm UTC](https://community.auth0.com/t/cli-command-to-update-html-universal-login-page/116261/7 "2023-09-18T21:49:10Z")

</div>

Hi @srajendran,

Thanks for following up.

These commands allow you to customize your Universal Login Custom HTML page.

Thanks,  
Rueben

---

<div class="post-metadata">

**Author:** ![srajendran](https://upload.wikimedia.org/wikipedia/commons/thumb/7/7c/User_font_awesome.svg/768px-User_font_awesome.svg.png) [@srajendran](https://community.auth0.com/u/srajendran)\
**Post date:** [September 25, 2023, 5:16pm UTC](https://community.auth0.com/t/cli-command-to-update-html-universal-login-page/116261/8 "2023-09-25T17:16:17Z")

</div>

> [@rueben.tiow](#):
>
> auth0 universal-login templates show

Hi Ruebe,  
When i try to curl, “curl -L ‘[https://login.auth0.com/api/v2/branding/templates/universal-login](https://login.auth0.com/api/v2/branding/templates/universal-login)’   
-H ‘Accept: application/json’”, it says missing authorization error. how do i get through this?

---

<div class="post-metadata">

**Author:** ![rueben.tiow](https://sea1.discourse-cdn.com/auth0/user_avatar/community.auth0.com/rueben.tiow/32/11646_2.png) [@rueben.tiow](https://community.auth0.com/u/rueben.tiow)\
**Post date:** [September 27, 2023, 6:48pm UTC](https://community.auth0.com/t/cli-command-to-update-html-universal-login-page/116261/9 "2023-09-27T18:48:09Z")

</div>

Hi @srajendran,

Thanks for the reply.

Using the Management API’s [Set template for New Universal Login experience endpoint](https://auth0.com/docs/api/management/v2/branding/put-universal-login), please use the following command to update your Universal Login HTML page:

```auto
curl -L -X PUT 'https://YOUR_DOMAIN.REGION.auth0.com/api/v2/branding/templates/universal-login' \
-H 'Content-Type: application/json' \
-H 'Authorization: Bearer {access_token}' \
-d '{"template":"<!DOCTYPE html><html><head>{%- auth0:head -%}</head><body>{%- auth0:widget -%}</body></html>"}'

```

Thanks,  
Rueben

---

<div class="post-metadata">

**Author:** ![system](https://global.discourse-cdn.com/auth0/original/3X/b/5/b560f266932fcce5d57f09a6595bd50518cae3f3.jpeg) [@system](https://community.auth0.com/u/system)\
**Post date:** [October 11, 2023, 6:48pm UTC](https://community.auth0.com/t/cli-command-to-update-html-universal-login-page/116261/10 "2023-10-11T18:48:45Z")

</div>

This topic was automatically closed 14 days after the last reply. New replies are no longer allowed.
