# Organization Sites





Sites deployed under an organization use a different URL format and share the organization's storage and site limits.

URL format [#url-format]

Organization sites are served at:

```
https://{siteSlug}--{orgSlug}.sample.app
```

For example, if your organization slug is `acme` and you deploy a site with slug `dashboard`, the URL is:

```
https://dashboard--acme.sample.app
```

Deploying via the dashboard [#deploying-via-the-dashboard]

1. Switch to your organization using the **OrgSwitcher** dropdown
2. Click **New Site** and follow the deploy flow
3. The site is created under the organization automatically

Deploying via the CLI [#deploying-via-the-cli]

One-time setup [#one-time-setup]

Run `samplex init` with the `--org` flag to save your organization context:

```bash
samplex init --org <organizationId>
```

This writes the organization ID to `.samplex.config.json`. All subsequent deploys from this directory go to the organization.

Deploy [#deploy]

```bash
samplex deploy ./dist
```

If you've run `samplex init --org` previously, the CLI uses the saved organization ID automatically.

Deploy with a flag [#deploy-with-a-flag]

Skip the init step and pass the organization directly:

```bash
samplex deploy --org <organizationId> ./dist
```

Deploy with an organization API key [#deploy-with-an-organization-api-key]

Organization API keys automatically scope deploys to the correct organization:

```bash
SAMPLEX_API_KEY=org_xxx samplex deploy ./dist
```

No `--org` flag or init step needed — the key determines the organization.

<Callout type="info">
  Find your Organization ID on the **Keys** page in your organization dashboard.
</Callout>

Site ownership [#site-ownership]

The deployer is recorded on every site, but the **organization owns** the site. This means:

* Members can delete their own sites
* Admins and owners can delete any site in the organization
* If a member is removed, their sites remain in the organization

Limits per plan [#limits-per-plan]

| Plan       | Sites     | Storage per site |
| ---------- | --------- | ---------------- |
| Free       | 3         | 15 MB            |
| Pro        | 50        | 500 MB           |
| Enterprise | Unlimited | Unlimited        |
