FXNook Vendor Docs

Adding Licensing to an EA

Download your licensing file, add one include line, compile and test.

Updated September 19, 2026 1 min read

Adding licensing takes a few minutes. You add one line to your source code; nothing else changes.

1. Download your licensing file

  1. In your Vendor Dashboard open EA Licensing and choose the product.
  2. Answer the questions about your code – see Answering the download questions. Not sure? The page has an Ask an AI box: copy its prompt into Claude or ChatGPT with your source code and it tells you what to tick.
  3. Click Download licensing file.
  4. Extract the ZIP into the MQL4/Include/ or MQL5/Include/ folder of your MetaTrader data folder, so the file ends up in Include/FXNook/.

2. Add the include line

Make this the very first line of your source file, above everything else. Use the exact line shown on the download page:

#include <FXNook/FXNook_License_1234.mqh>

3. Compile

Compile as normal in MetaEditor. The file renames your OnInit and OnTick as the compiler reads them and puts the licence check in front. If you see an error, see Compile errors and what they mean.

4. Test before uploading

  1. In MetaTrader add https://fxnook.com under Tools > Options > Expert Advisors > Allow WebRequest for listed URL.
  2. Attach your compiled EA with an empty licence key.
  3. You must see a red LICENCE CHECK FAILED – NOT TRADING panel in the top-left, and a line starting FXNook: in the Experts tab.

A smiley face and no FXNook badge means licensing is not active. Do not upload that build.

5. Upload

Upload the compiled .ex4 or .ex5 to your product. Keep the .mqh private – see Security rules.

    Was this guide helpful?
    Need help? Most questions are answered by the guides above. If yours is not, our team will help.
    Open Support Ticket