# Troubleshooting





Authentication [#authentication]

<Accordions type="single">
  <Accordion title="&#x22;Not logged in&#x22; error">
    Your token may have expired or been invalidated.

    **Fix:** Run `samplex login` to re-authenticate.
  </Accordion>

  <Accordion title="Token refresh fails">
    The CLI refreshes tokens automatically. If refresh fails:

    1. Delete the credentials file: `rm ~/.samplex/credentials.json`
    2. Run `samplex login` again
  </Accordion>
</Accordions>

Deployments [#deployments]

<Accordions type="single">
  <Accordion title="&#x22;Bundle too large&#x22; error">
    The maximum compressed archive size is **100 MB**.

    **Fix:** Reduce your bundle size. Common culprits:

    * Unminified JavaScript or CSS
    * Large images (consider compressing or using a CDN)
    * Source maps included in the output directory
  </Accordion>

  <Accordion title="&#x22;Slug already taken&#x22; error">
    Site slugs must be unique per user.

    **Fix:** Choose a different slug with `--slug`, or delete the existing site first:

    ```bash
    samplex delete <slug>
    ```
  </Accordion>

  <Accordion title="Deploy seems stuck">
    If the upload takes longer than expected:

    1. Check your internet connection
    2. Verify the output directory isn't unexpectedly large: `du -sh ./dist`
    3. Make sure you're deploying the build output, not the source directory

    <Callout type="warn">
      Deploying your source directory instead of the build output is the most common cause of slow or
      stuck deploys.
    </Callout>
  </Accordion>

  <Accordion title="Site shows old content after deploy">
    Deployments are served from edge caches. After a new deploy, it may take a few seconds for caches to update.

    **Fix:** Hard-refresh your browser (`Cmd+Shift+R` or `Ctrl+Shift+R`).
  </Accordion>
</Accordions>

Verifying your setup [#verifying-your-setup]

To check what's currently deployed:

```bash
samplex list
```

This shows all your sites with their status, URL, and size.
