# Setting up WiFi-based check-in using MikroTik

### What do I need? <a href="#what-do-i-need" id="what-do-i-need"></a>

To allow your customers to [check in](/platform/day-to-day/operations/check-in.md) using Wi-Fi, you must first enable this feature in your location's settings.

### MikroTik Devices

If you want to use a MikroTik device with the network check-in system on your Nexudus Spaces account you need a MikroTik device running RouterOS 6.2 or newer. Usually, you need a level 6 license for the device. Most resellers provide the hardware and the license in a single package. The RouterOS is already installed, as with any other router in the market. Make sure you buy the right license level. License levels affect the number of logged-in users at the same time that the router can authenticate. A level 6 router does not have such limitation and can support any number of users.&#x20;

### Installing MikroTik <a href="#installing-mikrotik" id="installing-mikrotik"></a>

All RouterOS routers can be configured using a web portal. If you are on a Windows machine, MikroTik provides a Winbox configuration tool. Using the Winbox software is faster than accessing the web interface when configuring the device. We use Winbox in this guide. You can get this tool from [here](http://www.mikrotik.com/download).‌

The configuration we describe in this guide does not affect any other MikroTik features.

We cannot provide networking and IT support with installing or troubleshooting your network. These instructions are meant for people with a basic level of experience when using MikroTik devices. The instructions are not a detailed tutorial or manual on how to install and use MikroTik. If you need more help, we can get you in touch with a MikroTik consultant who can configure your MikroTik device and provide support.‌

This guide does not cover the basics of how to install a router. Connect your internet provider cable to the port #1 on the MikroTik router. The rest of the ports are used for your internal network. When you install the router and have internet access, you can then follow this guide. You can see the basic configuration overview in the image below\.MikroTik installation overview‌

![MikroTik installation overview](https://blobscdn.gitbook.com/v0/b/gitbook-28427.appspot.com/o/assets%2F-LZFtxNPXnGfu3w0vzug%2F-LaQOraK3dkv9bhvfyEx%2F-LaQQItkMuu6yxCL2mNu%2Fmikrotik_installation_overview.png?alt=media\&token=82526bda-9f54-4974-beae-c86bcca7e7c9)

MikroTik routers use the term *hotspot* to describe the authentication portals which control access to the internet. In guides for other virtual controllers, we use *captive portal* to describe such authentication portals.‌

You need a hotspot with modified HTML pages that allow relaying authentication to our servers. All check-in and member information is stored there. Set the hotspot authentication to **MAC HTTP CHAP.** In the **Mac Auth Mode**, make sure you select **MAC** in the **Username** fiel&#x64;**.**&#x4D;icroTik hotspot authenitcation mode‌

![MicroTik hotspot authenitcation mode](https://blobscdn.gitbook.com/v0/b/gitbook-28427.appspot.com/o/assets%2F-LZFtxNPXnGfu3w0vzug%2F-LaQOraK3dkv9bhvfyEx%2F-LaQYK_as1z5nNid84fV%2Fmikrotik_mac_auth_mode.png?alt=media\&token=b5865574-4b8a-44d9-b8a8-bcfe36b13805)

The MikroTik hotspot requires only one user. You need to enter these details on your Nexudus Spaces account by going to **Settings** > **Integrations** and clicking **MikroTik** in the **Active integrations** section. The user profile needs to allow shared users. We set **admin** as the shared user in the **Name** section.Selecting the user

![Selecting the user](https://blobscdn.gitbook.com/v0/b/gitbook-28427.appspot.com/o/assets%2F-LZFtxNPXnGfu3w0vzug%2F-LaQOraK3dkv9bhvfyEx%2F-LaQ_gVbsD3x0QOIOSAS%2Fmikrotik_hotspot_users.png?alt=media\&token=0a6dbca2-8c88-472b-b108-dd2cb7f5b565)

You must use the default user profile. Do not create a new user profile.‌

We set the **Shared Users** limit to 1000.Configuring User Profiles‌

![Configuring User Profiles](https://blobscdn.gitbook.com/v0/b/gitbook-28427.appspot.com/o/assets%2F-LZFtxNPXnGfu3w0vzug%2F-LaQOraK3dkv9bhvfyEx%2F-LaQab-AGuAq0L4_C89i%2Fmikrotik_hotspot_user_profile.png?alt=media\&token=e628a543-0bef-41ef-8a54-f6d5efb6236a)

Download the HTML pages from your Nexudus account by going to **Settings** > **Integrations** and clicking **MikroTik** in the **Active integrations** section and then clicking **Download Hotspot HTML files**. Create a new hotspot folder for your router named **nexudus**. You can do this using the **Files** feature in Winbox.

When you create the hotspot folder, copy all the files from the default folder to the **nexudus** folder. Then, replace the 3 files in the **nexudus** folder with the files you downloaded from your Nexudus account. The best way to do this may be to drag the default folder to your local computer and then drag it back to the new folder.‌

The downloaded files already have the required configuration from your account settings, so you only need to move them to the right folder and copy the scripts. We explain how to do this in the following sections.Folder structure‌

‌

![Folder structure](https://blobscdn.gitbook.com/v0/b/gitbook-28427.appspot.com/o/assets%2F-LZFtxNPXnGfu3w0vzug%2F-LaQOraK3dkv9bhvfyEx%2F-LaQne4wI5oyEudn77eL%2Fmikrotik_hotspot_files_location.png?alt=media\&token=78ad41ee-108d-4a30-a110-071da875ff00)

You need add several addresses to the **Walled Garden IP List** so members can browse your site. In case they need to buy access to the space, manage their account and login. Add the following addresses to the list:‌

* ajax.googleapis.com
* maps.googleapis.com
* fonts.googleapis.com
* pki.goog
* gstatic.com
* googleapis.com
* apis.google.com
* [www.google.com](http://www.google.com)
* [www.paypalobject.com](http://www.paypalobject.com)
* themes.googleusercontent.com
* maps.gstatic.com
* twimg.com
* platform.twitter.com
* multigateway.nexudus.com
* checkout.stripe.com
* q.stripe.com
* api.stripe.com
* netdna.bootstrapcdn.com
* cdnjs.cloudflare.com
* sandbox.forte.net
* api.mixpanel.com
* s3.amazonaws.com
* cdn.syndication.twimg.com
* XYZ.spaces.nexudus.com, where **XYZ** is the default domain name you can find in **Settings** > **Website** > **General** on your Nexudus account.

‌

When logging in to the hotspot, users are automatically redirected to Nexudus. They see the page below:MikroTik hotspot logging screen for unknown users‌

‌

![MikroTik hotspot logging screen for unknown users](https://blobscdn.gitbook.com/v0/b/gitbook-28427.appspot.com/o/assets%2F-LZFtxNPXnGfu3w0vzug%2F-LaQOraK3dkv9bhvfyEx%2F-LaQiQ2pFvWbo89BfyTP%2Fmikrotik_login_unkonwn.png?alt=media\&token=b1bff2ae-1146-461e-adf8-e78238c54e6f)

When we know who they are based on their MAC address, the see a different page:MikroTik hotspot logging screen for known users‌

![MikroTik hotspot logging screen for known users](https://blobscdn.gitbook.com/v0/b/gitbook-28427.appspot.com/o/assets%2F-LZFtxNPXnGfu3w0vzug%2F-LaQOraK3dkv9bhvfyEx%2F-LaQisVUioSXYiVs7Sgx%2Fmikrotik_login_known.png?alt=media\&token=c386d80d-242c-4553-a6fb-95162fcdc7f6)

In any case, there is a link to register and to buy access time if you have those options enabled on your Nexudus account and have products added to sell [passes.](https://app.gitbook.com/@3di/s/nexudus-help-center/day-to-day/day-to-day-operations/managing-products)​‌

You need to use the scripts provided in the zip file. Paste the content of the scripts folder in the default user profile, making sure you use file **OnLogin\_Script.txt** for the **On Login** script and the **OnLogout\_Script.txt** file for the **On Logout** script.Setting up scripts‌

![Setting up scripts](https://blobscdn.gitbook.com/v0/b/gitbook-28427.appspot.com/o/assets%2F-LZFtxNPXnGfu3w0vzug%2F-LaQOraK3dkv9bhvfyEx%2F-LaQkGlh2lcV6OZYYM6L%2Fmikrotik_hotspot_scripts.png?alt=media\&token=13a23063-8cf2-41a4-aabe-c37aedfa6831)

Edit the hotspot profile and enable **MAC** and **HTTP CHAP** login methods.Selecting hotspot login method‌

![Selecting hotspot login method](https://blobscdn.gitbook.com/v0/b/gitbook-28427.appspot.com/o/assets%2F-LZFtxNPXnGfu3w0vzug%2F-LaQOraK3dkv9bhvfyEx%2F-LaQktxBUSEVXlN8tuIY%2Fmikrotik_hotspot_auth.png?alt=media\&token=cf10aebd-b61a-4a85-854e-796435eaa018)

Create a third script called **CheckActiveUsers** and use the content of the **CheckActiveUsers\_Script.txt** file as the source for that script. Make sure to enable the **write**, **read** and **test** policies.Creating the CheckActiveUsers script and setting up script policies‌

![Creating the CheckActiveUsers script and setting up script policies ](https://blobscdn.gitbook.com/v0/b/gitbook-28427.appspot.com/o/assets%2F-LZFtxNPXnGfu3w0vzug%2F-LaQOraK3dkv9bhvfyEx%2F-LaQlwyJwWXjqTLLkmmU%2Fmikrotik_script_policies.png?alt=media\&token=7f6bcd29-21ca-44d7-8f7f-dc9da94cb390)

Create a new schedule in **System>Scheduler** to invoke this script every 15 minutes.Creating a new script schedule

![Creating a new script schedule](https://blobscdn.gitbook.com/v0/b/gitbook-28427.appspot.com/o/assets%2F-LZFtxNPXnGfu3w0vzug%2F-LaQOraK3dkv9bhvfyEx%2F-LaQmiwTfcUdTIl8J7aX%2Fmikrotik_script_schedule.png?alt=media\&token=3164d3f9-c09c-42e9-a2dd-13fd1028cca0)


---

# Agent Instructions: Querying This Documentation

If you need additional information that is not directly available in this page, you can query the documentation dynamically by asking a question.

Perform an HTTP GET request on the current page URL with the `ask` query parameter:

```
GET https://legacydocs.nexudus.com/platform/settings/integrations-and-apps-1/wifi-based-check-in/network-based-check-in-mikrotik.md?ask=<question>
```

The question should be specific, self-contained, and written in natural language.
The response will contain a direct answer to the question and relevant excerpts and sources from the documentation.

Use this mechanism when the answer is not explicitly present in the current page, you need clarification or additional context, or you want to retrieve related documentation sections.
