In this method of “Web Filtering”, specific websites can be blocked on MikroTik using the Content Filter Rules. This filter can be found in the ‘Advanced’ tab while adding new firewall filter rules. Show
The MikroTik terminal command for adding the above rule is as follows: If there are multiple local networks created on the MikroTik router, the above rule created will block the website across all networks. If you want to block any website only on one particular networkIn order to block the website across only one network from among multiple networks created on
MikroTik, we specify the network on which the website is to be blocked in the Src. Address field in the General tab while adding the Block Website rule, as seen in the image below: The MikroTik terminal command for adding the above rule is as follows: The MikroTik terminal command for adding the above rule is as follows: If you want to block any website only on certain devicesIn order to block the website only for a certain device, there
are two methods through which this can be done: Method 1: We specify the static IP of the device in the Src. Address field in the General tab while adding the Block Website rule, as seen below: The MikroTik terminal command for adding the above rule is as
follows: Method 2: We specify the MAC address of the device in the Src. MAC Address field in the Advanced tab while adding the Block Website rule, as seen below: The MikroTik terminal command for adding the above rule is as follows: If you want to whitelist few devices for particular websites which are otherwise blockedIf a website is blocked across all networks, or on a certain network, but certain specific devices need to be given access to these sites, then we will create another filter rule and place it above the existing Website Blocking rule. We
recommend you read the below FAQ section in details. How can I block a website on MikroTik router?Step 1: Go to IP > Firewall. Click on the 'Filter Rules' tab. Click on '+' to add a new rule. Step 4: In the Action tab, Select Action as reject, then Select Reject With as icmp host unreachable.
How do I block Facebook and YouTube in MikroTik router script?Block Facebook, YouTube with MikroTik Filter Rule. Open winbox and login with your login credentials.. Go to IP > Firewall and then click on Layer7 Protocols tab.. Click on PLUS SIGN (+) to create a new Layer7 Protocol with Regex. ... . Put a meaningful name such as Facebook in Name input box.. Now put ^.. |