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

# Fix Common Bearsampp Issues and Error Messages

> Diagnose and resolve the most frequent Bearsampp errors, from startup failures and missing files to port conflicts and version mismatches.

When something goes wrong in Bearsampp, the application usually shows a specific error message or dialog. The issues below cover the most common problems users encounter and explain how to fix each one.

<AccordionGroup>
  <Accordion title="Bearsampp won't start — Administrator Rights Required">
    Bearsampp needs to install and manage Windows services, which requires elevated permissions.

    **How to fix:**

    1. Close any open instance of Bearsampp.
    2. Find `bearsampp.exe` in your Bearsampp folder.
    3. Right-click `bearsampp.exe` and select **Run as administrator**.
    4. Click **Yes** when Windows asks for confirmation.

    <Tip>
      To avoid this every time, right-click `bearsampp.exe`, go to **Properties → Compatibility**, and check **Run this program as an administrator**.
    </Tip>
  </Accordion>

  <Accordion title="A service failed to start">
    When Apache, MySQL, MariaDB, or another service cannot start, Bearsampp shows a startup error dialog. The most common cause is a port conflict — another application is already listening on the port that service needs.

    **How to diagnose:**

    1. Right-click the Bearsampp tray icon.
    2. Go to **\[module name] → Error logs** to read the most recent error output.
    3. Look for lines mentioning a port number or "Address already in use".

    If the logs point to a port conflict, see [Resolve Port Conflicts](/troubleshooting/port-conflicts) for step-by-step instructions.
  </Accordion>

  <Accordion title="Apache configuration file not found">
    Bearsampp shows a "configuration file not found" error when it cannot locate the Apache configuration file in the expected path. The module folder may be incomplete or corrupted.

    **How to fix:**

    1. Stop all Bearsampp services from the tray menu.
    2. Delete the affected Apache module folder (e.g., `bearsampp/bin/apache/apache2.4.x/`).
    3. Re-extract that module from the original Bearsampp archive, or download a fresh copy from [bearsampp.com](https://bearsampp.com).
    4. Restart Bearsampp.

    <Warning>
      Do not manually edit or rename files inside a module folder unless you know what you are doing. Bearsampp expects files to be at specific paths relative to the module root.
    </Warning>
  </Accordion>

  <Accordion title="Executable not found">
    A "executable file not found" error means the binary for a module (e.g., `apache.exe`, `php.exe`) is missing from its expected location.

    **How to fix:**

    1. Identify which module is affected from the error message.
    2. Check that the module folder exists under `bearsampp/bin/` and is not empty.
    3. If the folder is missing or incomplete, download the correct module version from [bearsampp.com/module](https://bearsampp.com/module) and re-extract it.
  </Accordion>

  <Accordion title="PHP and Apache incompatibility">
    Bearsampp shows a compatibility warning when the selected Apache version and PHP version are not compatible with each other. Not all combinations work together.

    **How to fix:**

    1. Right-click the tray icon and go to **Apache → Versions** to see which Apache version is active.
    2. Go to **PHP → Versions** and switch to a PHP version that is compatible with your Apache version.
    3. As a general rule, use PHP versions that were released during the same period as your Apache version.

    <Note>
      The Bearsampp release notes list supported PHP/Apache combinations for each release. Check the changelog if you are unsure which versions work together.
    </Note>
  </Accordion>

  <Accordion title="Port already in use">
    A "port is used by another application" message means another application on your system is already bound to the port Bearsampp needs. The service cannot start until the port is free.

    **How to fix:**

    1. Right-click the tray icon and go to **\[module name] → Change port**.
    2. Enter a new, unused port number (e.g., `8080` instead of `80`).
    3. Click **Finish**.
    4. Restart the service.

    For a full walkthrough including how to identify which application is occupying a port, see [Resolve Port Conflicts](/troubleshooting/port-conflicts).
  </Accordion>

  <Accordion title="You are already on version X">
    This message appears when you try to switch to a module version that is already the active version. Bearsampp prevents a redundant switch.

    **What to do:** No action is needed. The version you selected is already running. If you intended to switch to a different version, go back to the version list and select a different one.
  </Accordion>

  <Accordion title="Virtual host already exists">
    If you try to create a virtual host with a server name that is already configured, Bearsampp shows a "virtual host already exists" error.

    **How to fix:**

    * To edit the existing vhost, go to **tray → Apache → Virtual Hosts → Edit \[vhost name]**.
    * To delete it and start fresh, go to **tray → Apache → Virtual Hosts**, select the vhost, and delete it. Alternatively, remove its configuration file from `bearsampp/vhosts/`.
  </Accordion>

  <Accordion title="Alias name not valid">
    This error means the alias name you entered contains characters that are not allowed. Bearsampp alias names must be **alphanumeric only** — letters and numbers, no spaces, hyphens, or special characters.

    **How to fix:** Rename your alias using only letters and numbers (e.g., `myapp` instead of `my-app` or `my app`).
  </Accordion>

  <Accordion title="bearsampp.conf is malformed">
    A "config file malformed" error means Bearsampp's main configuration file has a syntax problem and cannot be parsed correctly.

    **How to fix:**

    1. Open `bearsampp/bearsampp.conf` in a plain text editor (e.g., Notepad).
    2. Look for any lines that appear broken, have unmatched quotes, or contain unexpected characters.
    3. If you have a backup (e.g., from a previous working state), restore it.
    4. If no backup exists, use **tray → Tools → Rebuild bearsampp.ini** to regenerate a default configuration, then re-apply your customizations.

    <Warning>
      Always make a backup of `bearsampp.conf` before editing it manually.
    </Warning>
  </Accordion>
</AccordionGroup>
