> ## Documentation Index
> Fetch the complete documentation index at: https://docs.moxycode.com/llms.txt
> Use this file to discover all available pages before exploring further.

# Troubleshooting

> Solutions to common issues with MoxyCode.

If you can't find a solution here, use the **Feedback** button at the bottom of the MoxyCode panel to contact support.

## Installation & sign-in

<AccordionGroup>
  <Accordion title="MoxyCode icon not appearing in the Activity Bar">
    The extension may not have activated yet. MoxyCode activates when a supported file type is opened.

    1. Open any `.cls`, `.trigger`, `.js`, or `.html` file
    2. Save the file once to trigger activation
    3. If the icon still doesn't appear, run **Developer: Reload Window** from the Command Palette
  </Accordion>

  <Accordion title="Magic link email not arriving">
    1. Check your spam or junk folder
    2. Make sure you are checking the inbox for the email address you entered
    3. The email is sent from `auth@moxycode.com` — add it to your safe senders list if needed
    4. Return to VS Code and click **Send Magic Link** again to request a new one

    <Note>
      Magic links expire after 15 minutes. If your link has expired, request a new one.
    </Note>
  </Accordion>

  <Accordion title="Magic link opened the website instead of VS Code">
    This happens when VS Code is not set as the default handler for `vscode://` links on your machine.

    1. Make sure VS Code is open before clicking the magic link
    2. Click the link again
    3. If your browser asks which app to open, select **Visual Studio Code**

    If the problem persists, try copying the link from your email and pasting it directly into your browser address bar with VS Code already open.
  </Accordion>

  <Accordion title="Sign-in prompt not appearing after 2 trial requests">
    The sign-in prompt triggers automatically on your third request. If it doesn't appear:

    1. Run **Developer: Reload Window** from the Command Palette
    2. Make the request again — the prompt should appear
  </Accordion>

  <Accordion title="Signed in but MoxyCode still showing trial mode">
    1. Run **Developer: Reload Window** from the Command Palette
    2. If the issue persists, try signing out and signing back in from the MoxyCode panel
  </Accordion>
</AccordionGroup>

***

## Deployment

<AccordionGroup>
  <Accordion title="MoxyCode: Deploy to Org not showing in the right-click menu">
    The deploy option only appears for supported file types. Make sure the file you are right-clicking is a `.cls`, `.trigger`, `.js`, or `.html` file.

    If the option still doesn't appear:

    1. Save the file once to trigger MoxyCode activation
    2. Run **Developer: Reload Window** from the Command Palette and try again
  </Accordion>

  <Accordion title="Deploy succeeds but changes aren't showing in the org">
    Make sure you are deploying to the correct org. Check your active Salesforce CLI default org:

    1. Look at the org name in the VS Code status bar at the bottom of the screen
    2. Click it to change to a different org if needed

    MoxyCode always deploys to whichever org is set as your Salesforce CLI default.
  </Accordion>

  <Accordion title="Deploy failing with authentication error">
    Your Salesforce CLI org session may have expired. Re-authenticate:

    1. Click the org name in the VS Code status bar
    2. Select **Authorize an Org** and follow the login flow
    3. Try deploying again
  </Accordion>

  <Accordion title="LWC deploy failing on a file I didn't change">
    LWC components deploy as a full bundle — all files in the component folder are deployed together. If another file in the bundle has an error, the deploy will fail even if you only changed one file.

    Check the Deploy Errors panel for the specific file and line causing the failure — it may not be the file you edited.
  </Accordion>

  <Accordion title="Salesforce CLI not found error">
    MoxyCode requires the Salesforce CLI to be installed and available in your terminal PATH.

    1. Run `sf --version` in your terminal to verify it is installed
    2. If not installed, download it from [developer.salesforce.com/tools/salesforcecli](https://developer.salesforce.com/tools/salesforcecli)
    3. After installing, run **Developer: Reload Window** in VS Code and try again
  </Accordion>
</AccordionGroup>

***

## Deploy Errors panel

<AccordionGroup>
  <Accordion title="Deploy Errors panel didn't open after a failed deploy">
    MoxyCode only monitors deploys triggered via **MoxyCode: Deploy to Org**. If you used the Salesforce CLI directly or an SFDX command, MoxyCode will not detect the errors.

    Always use **MoxyCode: Deploy to Org** from the right-click menu or Command Palette to get automatic error detection.
  </Accordion>

  <Accordion title="Explain button not responding">
    Check the following:

    1. Make sure you have remaining AI requests — Free plan users get 5 per day shared across the entire product
    2. Check your internet connection — Explain requires an active connection in online mode
    3. Check the **Online AI Usage** indicator in the panel header — if online credit is exhausted, switch to Offline Mode
  </Accordion>

  <Accordion title="Analyze & Generate Fixes button shows Upgrade to Pro">
    Analyze & Generate Fixes is a Pro feature. On the Free plan, click **Explain** on each individual error to get AI analysis and a suggested fix you can copy manually.

    [Upgrade to Pro → moxycode.com](https://moxycode.com)
  </Accordion>

  <Accordion title="Fix applied but the code looks wrong">
    1. Click **Undo Fix** in the notification that appeared after applying, or use `Cmd+Z` / `Ctrl+Z` to revert
    2. Review the **Confidence** and **Risk** ratings before re-applying
    3. For **Low Confidence** fixes, consider applying the change manually using the explanation as a guide
    4. Use the chat input at the bottom of the panel to ask MoxyCode for more context or an alternative approach
  </Accordion>

  <Accordion title="Deploy still failing after applying all fixes">
    Some errors are layered — fixing one can reveal another underneath. Run **MoxyCode: Deploy to Org** again. MoxyCode will open the panel with the next set of errors and repeat the fix cycle.
  </Accordion>

  <Accordion title="Chat not responding in the Deploy Errors panel">
    1. Check your internet connection
    2. Check you have remaining AI requests — each chat message uses 1 of your 5 daily requests on the Free plan
    3. Run **Developer: Reload Window** from the Command Palette and try again
  </Accordion>
</AccordionGroup>

***

## Code Analysis

<AccordionGroup>
  <Accordion title="No highlighted lines or CodeLens links appearing">
    MoxyCode analysis runs on file open and on save. Try the following:

    1. Save the file once to trigger analysis
    2. If nothing appears, run **Developer: Reload Window** from the Command Palette
    3. Reopen the file and save again
  </Accordion>

  <Accordion title="Explain & Fix All Warnings not visible">
    Explain & Fix All Warnings is a Pro feature and is not shown to Free plan users. On the Free plan, use the **MoxyCode: 💡 Explain & Fix** CodeLens link above each individual flagged line.

    [Upgrade to Pro → moxycode.com](https://moxycode.com)
  </Accordion>

  <Accordion title="Apply Fix button is locked">
    Apply Fix requires a Pro plan. On the Free plan, the full analysis and fixed code are shown in the Code Analysis panel — copy the fixed code and apply it manually to your file.

    [Upgrade to Pro → moxycode.com](https://moxycode.com)
  </Accordion>

  <Accordion title="Warnings not clearing after applying a fix">
    After applying a fix, save the file to confirm the changes. MoxyCode will re-analyse the file on save and update the warnings. If a warning persists after saving, the fix may not have fully resolved the issue — click **MoxyCode: 💡 Explain & Fix** again for further analysis.
  </Accordion>

  <Accordion title="Too many warnings appearing at once">
    Start with 🔴 **Critical** issues — these are the most likely to cause deployment failures or governor limit errors. Address 🟡 **Warning** issues next, then 🔵 **Info** items at your own pace.

    See the [Code Analysis Rules](/reference/code-analysis-rules) page for a full explanation of each rule.
  </Accordion>
</AccordionGroup>

***

## AI requests & plan

<AccordionGroup>
  <Accordion title="Hit the 5 request limit on the Free plan">
    The 5 daily AI request limit resets 24 hours after your 5th request was made. You can still deploy, view warnings, and navigate your code normally while waiting for the reset.

    [Upgrade to Pro for unlimited requests → moxycode.com](https://moxycode.com)
  </Accordion>

  <Accordion title="Not sure how many requests I have left">
    The Free plan request counter is shown in the MoxyCode panel header — **Free · x/5 requests**. This updates after each AI action.
  </Accordion>

  <Accordion title="Upgraded to Pro but extension still showing Free">
    1. Run **Developer: Reload Window** from the Command Palette
    2. If it still shows Free, sign out and sign back in from the MoxyCode panel
    3. If the issue persists, use the **Feedback** button in the panel to contact support
  </Accordion>
</AccordionGroup>

***

## Performance & connectivity

<AccordionGroup>
  <Accordion title="MoxyCode is slow to respond">
    Response time depends on your internet connection and current AI service load. If responses are consistently slow:

    1. Check your internet connection
    2. Check the **Online AI Usage** indicator — high usage may affect response times
    3. Consider switching to **Offline Mode** for faster local responses (Pro only)
  </Accordion>

  <Accordion title="MoxyCode showing Offline in the panel header">
    The **Offline** indicator in the panel header means MoxyCode cannot reach the AI service.

    1. Check your internet connection
    2. If you are on a corporate network, check whether outbound HTTPS traffic is restricted
    3. If you have Offline Mode set up, you can switch to it via **MoxyCode: Mode** in Settings
  </Accordion>

  <Accordion title="MoxyCode not working on a corporate or restricted network">
    MoxyCode requires outbound HTTPS access to function in online mode. If your network restricts outbound traffic, contact your IT team to whitelist the MoxyCode backend.

    Alternatively, set up **Offline Mode** (Pro) to run MoxyCode fully locally with no outbound connections required.
  </Accordion>

  <Accordion title="VS Code running slowly after installing MoxyCode">
    MoxyCode analysis runs on file open and save. If VS Code feels slower on large files:

    1. Run **Developer: Reload Window** to clear any stale processes
    2. If the issue persists, use the **Feedback** button in the panel to report it with details of the file size and type
  </Accordion>
</AccordionGroup>

***

<CardGroup cols={2}>
  <Card title="Plans & Limits" icon="credit-card" href="/help/plans-and-limits">
    Understand request limits and what Pro unlocks
  </Card>

  <Card title="Privacy & FAQ" icon="shield" href="/help/privacy-and-faq">
    How MoxyCode handles your code and data
  </Card>
</CardGroup>
