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

# Onboard a gateway

> Connect a Nano Pi or MikroTik gateway to your WifiPadi account.

A **gateway** is the router at your location. Your customers connect to the gateway for WiFi. WifiPadi supports two gateway types: our pre-flashed **Nano Pi**, and your own **MikroTik** router. This procedure takes about 5 minutes.

<Note>
  Complete [Set up your account](/account-setup) before you start. You need at least one location and one WiFi plan.
</Note>

<Tabs>
  <Tab title="Nano Pi (OpenWrt)">
    <Steps>
      <Step title="Connect the Nano Pi to the internet">
        Plug the port labeled **WAN / Internet** into your existing router or modem. Power on the Nano Pi. Wait 1 minute for it to start.
      </Step>

      <Step title="Connect to the Nano Pi">
        The Nano Pi ships ready to use. You do not install anything on the device itself.

        Connect a laptop to one of the other ports on the Nano Pi with an Ethernet cable. Open a terminal on the laptop and enter this command:

        ```bash theme={null}
        ssh root@192.168.1.1
        ```

        At the password prompt, press Enter. The Nano Pi has no password.

        <Note>
          If your laptop already uses a `192.168.1.x` address on another network, disconnect from that network first.
        </Note>
      </Step>

      <Step title="Add the gateway in your dashboard">
        In a browser, go to **Gateways → Add gateway**. Select **Nano Pi + OpenWrt** as the device type. Enter a name, for example `Gate-01`. Select the location for this gateway.
      </Step>

      <Step title="Run the install command">
        Your dashboard shows a one-line install command and a **Copy command** button. Copy the command. Paste it into the SSH session from step 2. Press Enter.

        The command sets up the connection to WifiPadi and configures the captive portal.
      </Step>

      <Step title="Confirm the gateway is online">
        In your dashboard, watch the gateway status move through 5 stages:

        1. Installing packages
        2. Configuring captive portal
        3. Installing portal agent
        4. Registering
        5. **Online**

        This takes 1 to 2 minutes. When the status shows **Online**, the gateway is ready. You can disconnect your laptop.
      </Step>
    </Steps>
  </Tab>

  <Tab title="MikroTik (RouterOS)">
    <Steps>
      <Step title="Add the gateway in your dashboard">
        Go to **Gateways → Add gateway**. Select **MikroTik (RouterOS)** as the device type. Enter a name. Select the location for this gateway.
      </Step>

      <Step title="Copy the install command">
        Your dashboard shows a RouterOS command. Select **Copy command**.
      </Step>

      <Step title="Run the command on your router">
        Open a terminal in Winbox, or connect by SSH to the router. Paste the command and press Enter.

        This command sets up the WireGuard tunnel, the RADIUS client, and the hotspot configuration. You do not need any other manual configuration in RouterOS.
      </Step>

      <Step title="Confirm the gateway is online">
        In your dashboard, watch the gateway status move through the same 5 stages, ending in **Online**. This takes 1 to 2 minutes.
      </Step>
    </Steps>
  </Tab>
</Tabs>

## Troubleshooting

<AccordionGroup>
  <Accordion title="The status stays on 'Installing packages' for more than 5 minutes">
    The gateway needs a working internet connection on its WAN port to download packages. Check that the WAN cable connects to a working modem or router. Then run the install command again.
  </Accordion>

  <Accordion title="You cannot reach 192.168.1.1 on the Nano Pi">
    Check that your laptop does not already use a `192.168.1.x` address from another network. Check that your laptop connects to a non-WAN port on the Nano Pi.
  </Accordion>

  <Accordion title="The gateway never shows 'Online'">
    Run the install command again. It is safe to run more than once. If the gateway still does not come online, contact support and give your gateway name.
  </Accordion>
</AccordionGroup>
