Free RouterOS configuration generator (browser-based, no account)

Well, I do.
Let's agree to disagree.
If it costs nothing (as it should) to keep it consistent with the result of an /export, it should be kept as such.

In any case, and no matter which order is chosen for the tokens, it should be THE SAME everywhere, otherwise it becomes harder to read (let alone compare).

I wasn't talking about the (token) order, which should remain alphabetical, in my opinion too,

but about the fact that inevitably, like for example the MAC address,
it cannot be included in the initial configuration,
unless the MAC address is chosen in advance...
with all that this entails, for example,
the configuration script with a fixed MAC cannot be used en masse...

Yep, and it is simply fine for this (or that) "dynamic" setting, like the MAC and possibly a small number of other settings that need to be "generated" on the spot.

But, out of a - say - 100 lines configurations, those dynamic lines will be 1, 2, 3 or 4 at the most.

When doing a compare (against a previous export, against a different suggested configuration, against a hand made one, etc.) the LESS differences are found the easiest is to spot them, a different order of tokens will look as a different setting, increasing (artificially) the amount of differences.

Ah, allora...

if you put it that way, we agree, we're saying the same thing.
I understood that you didn't accept a single one... That's what was incomprehensible to me...

This is a wonderful tool. We use a CCR2004 and CapsMan V2 to provision 13 hAP AX S devices, used as APs only. The CapsMan handles security and 3 VLANs. The AP setup is simple, all ports including WiFi on the bridg, e, assign a static IP to the bridge, point it to the CapsMan controller. Provisioning these would be handy as we add more APs at more sites. Is there a setting on the AP portion of your configuration tool to point to a CapsMan controller? Maybe I'm overlooking it??

@duxgavin, Wi-Fi 7, and thank you for the device output

That /interface wifi print was exactly what was needed, and it corrected us on something we had wrong.

Our catalogue had the hAP be³ Media as wifi1=5GHz, wifi2=2.4GHz. Your device says otherwise:

1  wifi1  .band=2ghz-n
2  wifi2  .band=5ghz-be   mld-interface=mld1
3  wifi3  .band=6ghz-be   mld-interface=mld1

So wifi1 is 2.4, not 5. Fixed, and that model is now marked verified rather than derived from a spec sheet. The 6 GHz radio had also been missing entirely from our data, and the be lite had the wrong port count (it is one 2.5G plus three 1G).

MLO is in, built from your configuration rather than from my reading of the manual:

/interface wifi security
add authentication-types=wpa3-psk name=sec-mlo passphrase=... wps=disable
/interface wifi datapath
add bridge=bridge name=dp-mlo
/interface wifi configuration
add country=... datapath=dp-mlo mode=ap name=cfg-mlo ssid=MT-Home security=sec-mlo
/interface wifi
add comment="genconf: MLO group" configuration=cfg-mlo disabled=no mld-name=mld1 name=mld1
set wifi2 mld-interface=mld1
set wifi3 mld-interface=mld1

It only appears on 802.11be hardware with more than one radio, forces WPA3, puts the datapath on the MLD interface since that is the forwarding point, and defaults to leaving 2.4 GHz out of the group for exactly the reason you gave: that band is there for older and IoT clients, which gain nothing from MLO.


@rextended, three of yours

The MikroTik default firewall is now an option. Firewall section, first choice. Picking it emits 43 rules taken verbatim from MikroTik's published router-mode default configuration, defconf: comments and all, with none of ours mixed in. That took two attempts: the first still leaked our RAW bogon rules and the IPv6 section added a second copy of the IPv6 filter on top. A "stock" firewall quietly containing half our opinions would defeat the entire point.

This also settles the defconf naming argument. Those rules genuinely are the defaults, so defconf: is the honest label there, which is what jaclaz wanted, without breaking your rule that defconf must mean the real thing. Anything the tool writes itself stays genconf. The two positions turn out to be compatible once there are two rule sets.

The IPv6 firewall is now always generated. You were right and this was the worst thing in the thread. Our IPv6 section defaulted to off, and the entire module was gated behind it, so anyone who simply never opened that section got a device with an empty IPv6 filter table. Safe until something brings the stack up, and then wide open.

It is now emitted unconditionally, verified across every case that previously produced nothing: IPv6 section off, IPv6 on with its firewall off, the stock firewall with no IPv6, and roles that never mention IPv6 at all. Exactly one block in each, never two. There is no opt-out toggle, because a switch labelled "remove IPv6 protection" is an invitation. It is not silent either: a configuration that does not use IPv6 is told why the rules are there, since unexplained rules get deleted by whoever reads them next.

On band=, I have not touched it and I would rather ask than guess. You raised that specifying a band may restrict the radio to that standard rather than merely setting the operating mode. The wifi package manual says band "defaults to newest supported standard", which supports your point that specifying it may be unnecessary. duxgavin's device does show band=5ghz-be in use, so it is not fatal. But if selecting 5ghz-be excludes older clients, then our long standing 5ghz-ax has been excluding a/n/ac clients on every AP we have ever generated, which would be a significant bug. Do you know whether that restriction applies to the wifi package as it does to the legacy driver?

Your bridge MAC one-liner is elegant, and the loop over every bridge is better than our per-device approach. Noted for when we support multiple bridges properly.


@jaclaz, three of yours

Token order is now alphabetical everywhere. You were right that it was inconsistent, and rextended was right that alphabetical is the order. Output is now:

add action=accept chain=input comment="genconf: accept established,related,untracked" connection-state=established,related,untracked
add action=drop chain=input comment="genconf: drop invalid" connection-state=invalid

which matches an export line for line. That change touched every generated line and broke 21 test assertions, all of which were expectations about ordering rather than behaviour. Several were brittle in a second way, assuming adjacency, since comment= now sorts between things. Worth it for the reason you gave: a reordered line reads as a changed line in any diff.

The spaces around = in the preview: mitigated, but I could not reproduce it. Both previews here copy as name=bridge via the normal path, and the Copy button was never affected since it copies the script text rather than the rendering. But your output, add name = bridge protocol-mode = none with doubled spaces and spaced equals, is precisely the signature of a copy inserting whitespace at every inline element boundary, which some browsers do. The = is now inside the key's span instead of sitting between two spans, which halves those boundaries, so the worst case becomes extra spaces between tokens rather than a broken =. That is a mitigation for an inferred cause, not a confirmed fix. If you still see it, tell me which browser.

The MikroTik default firewall option is in, as above. And thank you for updating Compare_config to treat genconf as equal to defconf, and for linking the tool from it. To confirm publicly: genconf is a stable label. It will not be renamed. If we ever need another tag it will be an addition, not a rename of this one.


@luxyves, thank you, glad it is useful.


Test suites after all of the above: 1172 generate, 84 multi-device, 132 import. Every item has a regression test, including the ones that were only findable because someone here tried the thing on real hardware.

@davidreaton Thank you, and you were not overlooking it. It genuinely was not there.

The mode was in the list, so picking "Managed by CAPsMAN (CAP)" looked like it worked, but it emitted no wireless configuration at all. The wifi section assumed the CAPsMAN section would write the CAP side, and that section only runs on the controller. So configuring an access point on its own gave you a script with the bridge and an address and nothing whatsoever about CAPsMAN. That is worse than a missing feature, because it looks supported. Your thirteen hAP ax S are exactly the case it should have handled.

It is in now. Pick the AP role, set the wireless mode to managed by CAPsMAN, and you get:

with four settings alongside it:

Controller address, comma separated for several. Leave it empty and the access point discovers the controller by broadcast instead, and the tool tells you that only works when controller and AP share a layer 2 network. For your setup, naming the CCR2004 explicitly is the right choice.
Discovery interface, defaulting to your management VLAN when VLANs are configured, otherwise the bridge.
Lock to this controller, off by default, with a note that replacing the controller then means setting the AP up again.
Request a certificate from the controller.
The legacy wireless package is handled as well, since not everyone is on ax: that produces /interface wireless cap with the radios named and the bridge given.

Two things it deliberately does not do. It writes nothing about SSIDs, security or VLANs on the AP, because those come from the controller and duplicating them locally is how CAP configurations start fighting each other. And it reminds you that the switch port towards each AP needs the wifi VLANs tagged, since that is the part that is easy to forget when adding the fourteenth one.

Your description of the setup is what the AP role now produces: all ports and radios in one bridge, static address on the bridge, pointed at the controller. If you generate one for an hAP ax S and it differs from what you run today, I would like to know where, since you have the working reference and I do not.

@duxgavin @rextended @jaclaz FYI: if we don't reply right away, it's usually because we want to give you time to discuss before a decision is made from our end :slight_smile:

I understand, and I thank you for the consideration you give to what I write.

You must be joking :astonished_face:, we are used to the timely replies from Mikrotik support , either to tickets or to issues raised on the board, no problem there.

Can't say what you did, but the excess spaces (both the ones around the "=" - important and the other ones - less relevant) disappeared
I am always hesitant to make this kind of reports because of the browser/OS I normally use, it is more or less a daily fight to browse the internet on Windows XP, SP2, 32 bit, and yes, I know :wink:, however the one I am using, Supermium, is a decently recent Chrome spinoff/derivative version 132.0.6834.226) and everything is cool now :slightly_smiling_face:.

In any case I thought a little bit about the spreadsheet and I am working on a modified version that allows the user to choose which strings should be considered NOT different, this way the default will be comment="defconf" versus comment="genconf" but it can easy modified by the end user.

EDIT: Spreadsheet updated: Terse export converter and config compare - #3 by jaclaz

No we are not, we are commited to this tool, with the support it deserves.

(@jaclaz maakte een grapje!!!...)

MikroTik takes much longer to respond, and we're used to it, don't worry...

:yawning_face: yet another LLM driven development project. This is what, like the third time this week?

Is that an accusation?

Weten we, was klein beetje sarcasme :stuck_out_tongue:

LLM or not, at least it's something that, compared to others usless frills,
works and doesn't have hallucinations.

But if you want to suggest one of your own,
or one that already exists and contains nothing derived from LLM,
go ahead, post a link to something that does it better, or at least as well as this site...

And this is written by someone who is critical of AI,
but I'm seeing results here, and it's better than MikroTik's QuickSet!...

So as long as the evidence is better than the appearance... I'll bite my fingers here if AI is used...

The fun thing is, we're not doing anything special here, at least not technically. PHP has been able to echo text since 1995. A MikroTik config is nothing more than text that their engine interprets.

What matters is how you write it. Every item should be a dynamic item. You see a lot of people programming like echo "HELLO"; instead of pulling the data from the database. If you build it correctly, a request that looks huge from the outside can turn out to be as simple as adding a row to the database.

And if people create something, they need to do quality control on it. Sometimes that's a long job, sometimes it's very short. It all depends on whether your architecture is right.

But that's just my personal two cents.

Well, you are wrong!

It Is something special.

Three things that are far from common

  1. No buzzwords or meta-para-concepts
  2. Does what It promises to do [1]
  3. It Is actually curated, and with an open mind by the developer(s)

BTW It being better than Mikrotik's Quickset doesn't count, my cat (the black and white one, not the tabby one) can usually cat-type better configurations than Quickset.

[1] or even if It doesn't right now there are very good signs It will soon do

Yeah, it is actually. This forum has been overrun with people shilling their LLM written “agentic A.I.” slop, only for their “projects” to be abandoned within months if not sooner. You can claim you’re different, but it’s irrelevant until you’ve proven you are.

And even if you are different, slop is slop, no matter how much you try to gussy it up.

I like your direction here. The specifics on the config generation is fixable... organizing the concepts and UI is the hard work.

Is your work in some public repo? I like to ran this through my clunkers (and my tikoci tools), since I already have lots of tools that work with RouterOS's schema/structure, and if generation was tweaked to keep ether1...X, it be easy to run the generated multi-router topologies through a series of tests using CHR in tests (granted be capped at 1MB/s but for validating a topology works, speed does not matter).