Answers.Body: <p>Seems like this is something you'd do from your .htaccess file or public index.php files for each of the non-primary sites you define.</p>
  
  <p>For example if you have a <code>public_html/index.php</code> for your English primary site and a <code>public_html/de/index.php</code> for your German site, your German one would just <code>header("Location: http://mysite.com/503");</code> to redirect.</p>
  
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2018-05-07T10:00:49.983Z
Answers.Text: That might work for some cases, but I think it's not a user-friendly way to disable a site.
  
  For example, I am working on a website that has various countries sites in a different language, and I want to create extra countries and add data to these countries. But I do not want these to be available in the frontend yet. Wouldn't be simpler if I could have a lightswitch
    that would disable it?
Answers.UserDisplayName: bzin
Answers.ContentLicense: CC BY-SA 4.0
Answers.CreationDate: 2019-03-05T16:34:05.780Z
Answers.Text: Did you find a way bzin? Agree, it needs a simple way to disable for non-logged in users, but logged in admins can see it, whilst its in development. The only way I can think of is in the layout file at the top, check if user is an admin, and if they are not redirect to a 404. If they are, they will see the site as normal.
Answers.UserDisplayName: Laurence Cope
Answers.ContentLicense: CC BY-SA 3.0
Answers.CreationDate: 2018-03-26T05:02:51.203Z
Answers.LastActivityDate: 2018-03-26T05:02:51.203Z
Answers.UserDisplayName: Brad Bell
Body: <p>Is there a way to disable non-primary sites on a multisite setup so that users are redirected to a 503 template?</p>
  
  <p>I can't see any configurations that allow me to to this. All sites are either disabled or live. </p>
  
Tags: <craft3><multi-site>
Title: Disabling individual sites on a Craft 3 multisite
ThreadText: # Disabling individual sites on a Craft 3 multisite
  
  (Asked by: username_0 on 2018-03-23)
  
  Is there a way to disable non-primary sites on a multisite setup so that users are redirected to a 503 template?
  
  I can't see any configurations that allow me to to this. All sites are either disabled or live.
  
  **Tags:** craft3, multi-site
  
  
  ---
  
  ## 1 answers
  
  ### Answer by username_1 on 2018-03-26. Score: 1
  
  Seems like this is something you'd do from your .htaccess file or public index.php files for each of the non-primary sites you define.
  
  For example if you have a `public_html/index.php` for your English primary site and a `public_html/de/index.php` for your German site, your German one would just `header("Location: http://mysite.com/503");` to redirect.
  
  > **Comments:**
  > **username_2**: That might work for some cases, but I think it's not a user-friendly way to disable a site.  For example, I am working on a website that has various countries sites in a different language, and I want to create extra countries and add data to these countries. But I do not want these to be available in the frontend yet. Wouldn't be simpler if I could have a lightswitch   that would disable it?  
  > **username_3**: Did you find a way username_2? Agree, it needs a simple way to disable for non-logged in users, but logged in admins can see it, whilst its in development. The only way I can think of is in the layout file at the top, check if user is an admin, and if they are not redirect to a 404. If they are, they will see the site as normal.  
  
  ---
  
  