Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.

birdietorerik's avatar

Php artisan down

Hi!

Have created a application in Laravel 10.x But i dont want other users then me, to access to my application

I can use:

 php artisan down 

But the i cant use the system, is it possible to allow only some users to use application ? Other get message on screen = System is down

But not possible ?

0 likes
10 replies
Snapey's avatar
Snapey
Best Answer
Level 122

its covered in the docs. did you check?

birdietorerik's avatar

Hi!

Tryed with secret, dosent work:

php artisan down --secret="myABC4566xxxaaa"

Gives me error:

The "--secret option does not exist"
martinbean's avatar

@birdietorerik It exists for me in a Laravel 10 app:

sail@bd8860476f1b:/var/www/html$ php artisan --version
Laravel Framework 10.42.0
sail@bd8860476f1b:/var/www/html$ php artisan down --help
Description:
  Put the application into maintenance / demo mode

Usage:
  down [options]

Options:
      --redirect[=REDIRECT]  The path that users should be redirected to
      --render[=RENDER]      The view that should be prerendered for display during maintenance mode
      --retry[=RETRY]        The number of seconds after which the request may be retried
      --refresh[=REFRESH]    The number of seconds after which the browser may refresh
      --secret[=SECRET]      The secret phrase that may be used to bypass maintenance mode
      --with-secret          Generate a random secret phrase that may be used to bypass maintenance mode
      --status[=STATUS]      The status code that should be used when returning the maintenance mode response [default: "503"]
  -h, --help                 Display help for the given command. When no command is given display help for the list command
  -q, --quiet                Do not output any message
  -V, --version              Display this application version
      --ansi|--no-ansi       Force (or disable --no-ansi) ANSI output
  -n, --no-interaction       Do not ask any interactive question
      --env[=ENV]            The environment the command should run under
  -v|vv|vvv, --verbose       Increase the verbosity of messages: 1 for normal output, 2 for more verbose output and 3 for debug

Are you actually running Laravel 10.x?

Nonetheless, the answer your question, just restrict access to the app to your IP address?

birdietorerik's avatar

Hi!

Sorry, my mistace. I was using :

php artisan up --secret="myABC4566xxxaaa"

But when i use:

php artisan down --secret="myABC4566xxxaaa"

Its working ?

birdietorerik's avatar

@tykus Reading documentation is sometimes smart :)

Setting first secret:

php artisan down --secret="myABC4566xxxaaa"

Then i i want to use application, i first call my root application with secret. Working fine :)

Please or to participate in this conversation.