Introduction

Welcome to the official Trading Pine Lab documentation

Continuous Improvement

Our team is constantly working on optimizing and developing new features based on feedback from our community. Each update incorporates significant improvements to ensure the best trading experience.

Listening to Our Community

We greatly value the suggestions and comments from our users. Your feedback is essential to continue improving and adapting our solutions to the real needs of the market.

Do you have a suggestion? Please do not hesitate to contact us through our support channels or creating a ticket. Your opinion helps us to grow and improve.

Installation

Step-by-step guide to get started with Trading Pine Lab

1

Download

Note: The installation requires approximately 500 MB of free space. Make sure you have administrator permissions if you choose to install for all users.
2

Installation Process

Run the Installer

Execute the downloaded file to start the installation.

Select User

Choose whether to install for current user or all users

Installation

Wait while all components are installed

End

Complete the installation and run the application

Windows SmartScreen security:

During installation, Windows SmartScreen may display a security warning. This is a normal behavior of the Windows protection system:

  • It is a standard Windows security measure for new applications.
  • Our software is digitally signed and completely secure.
  • You can proceed with the installation by clicking on "More info" → "Run anyway."
1
User Selection

Choose whether to install only for your user or for all users of the system. We recommend individual installation for safety.

User selection at installation
2
Installation Location

Select the folder where Trading Pine Lab will be installed. By default the recommended path in AppData is used.

Installation folder selection
3
Installation Process

The progress bar shows the progress of the installation. Wait while all the necessary files are copied and installed.

Installation progress
4
Completion

Click "Finish" to complete the installation. Check the box if you want to run Trading Pine Lab immediately.

Completion of the installation
3

Activation

Enter Password

Enter the activation key that you received by mail

Manage License

Access "License" in the app to review or modify your license at any time.

1
Enter Password

Enter your License activation key. You can find it in your profile. The password must be entered exactly as you received it.

Enter activation key
2
License Management

Once activated, you will be able to view the details of your license, including the expiration date and the current status of the expiration date and the current status of the expiration date and the current status of the expiration date.

License management
Once the license is activated, you will have immediate access to all Trading Pine Lab features.

Need Help?

If you have problems during installation or activation, our support team is here to help you.

Contact Support

Configuration

TradingView to MT5

Credentials

Enter login, password and server of your MT5 account

Verify MT5

Verify the connection and your credentials with the button "Verify MT5".

Start Server

Start the server with the "Start Server" button. You now have the URL to indicate in the TradingView alerts.

TradingView Alert

Copy the URL displayed in the "Webhook" field from TradingView to MT5/MT4 and the JSON in the alert in TradingView. Done!

Note: Your credentials are stored securely and only on your local computer.
1
Credentials

Open Trading Pine Lab and go to the "TradingView to MT5/MT4" section, create a new MT5 Strategy and finish entering your credentials.

MT5 credentials configuration
2
Verify MT5

Click on the "Verify Connection" button to verify that the data is correct and there is a connection to MetaTrader 5.

MT5 connection verification
3
Check connection

If the connection is successful, a green check will be displayed next to the strategy name.

Server startup
4
Starts server

Click on the "Start Server" button to start the Trading Pine Lab server and you are ready to receive TradingView signals in your MetaTrader 5 account.

Server startup
5
TradingView Alert

Copy the URL displayed in the "Webhook URL" field from TradingView to MT5/MT4. Create an alert in TradingView and in the "Webhook URL" field in the "Notifications" section, paste the URL you copied.

TradingView alert configuration
6
Copy the JSON of the strategy

Copy the JSON of the strategy by clicking on the "Copy JSON" button.

TradingView alert configuration
7
JSON TradingView Alert

In the "Message" field of the "Configuration Options" section you must paste the JSON of the strategy.

TradingView alert configuration
Important: each terminal must have only 1 account connected. If you want to connect more than one account, you must duplicate the terminal and associate the new account to that terminal.
Important: Generally, it is not necessary to modify any JSON parameters. The only exception is when the ticker in TradingView is different from the ticker in MT5/MT4. For example, if you trade BTC/USDT in TradingView but your MT5/MT4 broker only accepts BTC/USD, you will have to modify the "symbol" field manually, changing "{{ticker}}" to "BTC/USD".
JSON Alert:
{
    "action": "{{strategy.order.action}}",
    "contracts": "{{strategy.order.contracts}}",
    "marketPosition": "{{strategy.market_position}}",
    "positionSize": "{{strategy.position_size}}",
    "prevMarketPosition": "{{strategy.prev_market_position}}",
    "price": "{{close}}",
    "symbol": "{{ticker}}",
    "time": "{{timenow}}",
    "key": "XXX-XXXXX-XXXX-XXXX",
    "terminal": "X",
    "webhook": "https://XXXXXXXXXXXXXXXXXXXX.tradingpinelab.es/webhook/XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
    "port": X,
    "roundLotsMT4": X
}
Explanation of the fields:
  • action: Type of order (buy/sell)
  • contracts: Size of the operation to be executed (0.01, 0.5, 10, etc...)
  • marketPosition: Current market position (long, short, flat)
  • positionSize: Total position size (0.01, 0.5, 10, etc...)
  • prevMarketPosition: Previous market position (long, short, flat)
  • price: Current asset price (309.68, 115623.23, 0.0004164, etc...)
  • symbol: Symbol/Ticker of the asset (BTC/USD, TSLA, etc...)
  • time: Signal time (2025-01-01T12:00:00:00.000Z)
  • key: Internal key of the strategy created in Trading Pine Lab (XXX-XXXXX-XXXXXX-XXXX-XXXXXX)
  • terminal: Target terminal (mt4, mt5)
  • webhook: URL where the signals will be received (https://XXXXXXXXXXXXXXXXXXXX.tradingpinelab.es/webhook/XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX)
  • port: Connection port (5010, 5011, 5012, etc...)
  • roundLotsMT4: Lot rounding for MT4 (false, true)
Important: you must have "Algorithmic Trading" enabled in your MetaTrader 5 terminal and added the asset to trade in the "Market Watch" table.
MT5 Configuration

TradingView to MT4

Install the EA in MT4

Click on the "Install EA MT4 Destination" button and select the MT4 terminal.

Adds the EA to any symbol

The higher the number of ticks the better.

Start Server

Start the server with the "Start Server" button. You now have the URL to indicate in the TradingView alerts.

TradingView Alert

Copy the URL displayed in the "Webhook" field from TradingView to MT5/MT4 and the JSON in the alert in TradingView. Done!

Note: you must run an MT4 terminal for each separate account.
1
Terminal

Open Trading Pine Lab and go to the "TradingView to MT5/MT4" section, create a new MT4 Strategy and select the MT4 terminal.

MT4 credentials configuration
2
Install the EA in MT4

Click on the "Install EA MT4 Destination" button and select the MT4 terminal.

Installation of EA MT4
3
Configure the EA

Check that the EA "TradingView_MT4_to_MT4_Tradingpinelab" is installed on your MT4 terminal, it should appear in the "Expert Advisors" section.

TradingView alert configuration
4
Adds the EA to any symbol

Add the EA to any symbol you want to trade, the higher the number of ticks the better. Remember to check the "Allow DLL import" and "Allow automatic trading" options.

MT4 connection verification
5
Verify the connection to the MT4 terminal

Click on the "Verify connection" button to verify that the connection to the MT4 terminal is correct. Remember to have the terminal open and the EA installed and active.

MT4 connection verification
6
Check connection

If the connection is successful, a green check will be displayed next to the strategy name.

MT4 connection verification
7
Start Server

Click on the "Start Server" button to start the Trading Pine Lab server and you are ready to receive TradingView signals in your MetaTrader 4 account.

Server startup
8
TradingView Alert

Copy the URL displayed in the "Webhook URL" field from TradingView to MT5/MT4. Create an alert in TradingView and in the "Webhook URL" field in the "Notifications" section, paste the URL you copied.

TradingView alert configuration
9
Copy the JSON of the strategy

Copy the JSON of the strategy by clicking on the "Copy JSON" button.

TradingView alert configuration
10
JSON TradingView Alert

In the "Message" field of the "Configuration Options" section you must paste the JSON of the strategy.

TradingView alert configuration
Important: each terminal must have only 1 account connected. If you want to connect more than one account, you must duplicate the terminal and associate the new account to that terminal.
Important: Generally, it is not necessary to modify any JSON parameters. The only exception is when the ticker in TradingView is different from the ticker in MT5/MT4. For example, if you trade BTC/USDT in TradingView but your MT5/MT4 broker only accepts BTC/USD, you will have to modify the "symbol" field manually, changing "{{ticker}}" to "BTC/USD".
JSON Alert:
{
    "action": "{{strategy.order.action}}",
    "contracts": "{{strategy.order.contracts}}",
    "marketPosition": "{{strategy.market_position}}",
    "positionSize": "{{strategy.position_size}}",
    "prevMarketPosition": "{{strategy.prev_market_position}}",
    "price": "{{close}}",
    "symbol": "{{ticker}}",
    "time": "{{timenow}}",
    "key": "XXX-XXXXX-XXXX-XXXX",
    "terminal": "X",
    "webhook": "https://XXXXXXXXXXXXXXXXXXXX.tradingpinelab.es/webhook/XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX",
    "port": X,
    "roundLotsMT4": X
}
Explanation of the fields:
  • action: Type of order (buy/sell)
  • contracts: Size of the operation to be executed (0.01, 0.5, 10, etc...)
  • marketPosition: Current market position (long, short, flat)
  • positionSize: Total position size (0.01, 0.5, 10, etc...)
  • prevMarketPosition: Previous market position (long, short, flat)
  • price: Current asset price (309.68, 115623.23, 0.0004164, etc...)
  • symbol: Symbol/Ticker of the asset (BTC/USD, TSLA, etc...)
  • time: Signal time (2025-01-01T12:00:00:00.000Z)
  • key: Internal key of the strategy created in Trading Pine Lab (XXX-XXXXX-XXXXXX-XXXX-XXXXXX)
  • terminal: Target terminal (mt4, mt5)
  • webhook: URL where the signals will be received (https://XXXXXXXXXXXXXXXXXXXX.tradingpinelab.es/webhook/XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX)
  • port: Connection port (5010, 5011, 5012, etc...)
  • roundLotsMT4: Lot rounding for MT4 (false, true)
Important: you must have "Algorithmic Trading" enabled in your MetaTrader 4 terminal and added the asset to trade in the "Market Watch" table.
MT5 Configuration

TradingView to NinjaTrader

Download our connector

Download our connector and activate it in NinjaTrader

Verify NinjaTrader

Verify connection and saved data with the "Verify connection" button.

Start Server

Start the server with the "Start Server" button. You now have the URL to indicate in the TradingView alerts.

TradingView Alert

Copy the URL displayed in the "Webhook" field from TradingView to NinjaTrader and the JSON in the alert in TradingView. Done!

1
Create a new strategy

Open Trading Pine Lab and go to the "TradingView to NinjaTrader" section and create a new strategy.

MT5 credentials configuration
2
Download our connector

Click on the "Download Ninjatrader Connector" button to download our connector to your computer.

MT4 connection verification
3
Activates the connector

Activate the connector in NinjaTrader and restart the application. Tools > Import > NinjaScript Add-On... and select the downloaded connector (.zip file).

Server startup
4
Restart Trading Pine Lab

Restart Trading Pine Lab to load the connector.

Server startup
5
Configure the previously created strategy

Configure the previously created strategy. Select the terminal, the account and the symbol.

TradingView alert configuration
6
Verify the connection

Verify the connection by clicking on the "Verify connection" button.

TradingView alert configuration
7
Starts the server

Start the server with the "Start Server" button. That's it! You can now receive TradingView signals in your NinjaTrader account.

TradingView alert configuration
8
TradingView Alert

Copy the URL displayed in the "Webhook" field from TradingView to NinjaTrader. Create an alert in TradingView and in the "Webhook URL" field in the "Notifications" section, paste the URL you copied.

TradingView alert configuration
9
Copy the JSON of the strategy

Copy the JSON of the strategy by clicking on the "Copy JSON" button.

TradingView alert configuration
10
JSON TradingView Alert

In the "Message" field of the "Configuration Options" section you must paste the JSON of the strategy.

TradingView alert configuration

TradingView to cTrader

Login to cTrader

Go to the "TradingView to cTrader" section. Create a new login for cTrader and authenticate your account.

Create a new strategy

Create a strategy and enter the login, account and symbol data. Verify the connection with the "Verify connection" button.

Start Server

Start the server with the "Start Server" button. You now have the URL to indicate in the TradingView alerts.

TradingView Alert

Copy the URL shown in the "Webhook" field from TradingView to cTrader and the JSON in the alert in TradingView. Done!

1
Create a new login for cTrader

Open Trading Pine Lab and go to the "TradingView to cTrader" section and create a new login for cTrader.

MT5 credentials configuration
2
Authentication

Authenticate the created login in cTrader.

MT4 connection verification
3
Confirm accounts in the Authenticator

Select the accounts you want to use and confirm in the Authenticator.

Server startup
4
Finish the process

If everything went well, you will see a success page indicating that the login has been created correctly and you can close the window.

Server startup
5
Verify accounts in Trading Pine Lab

Confirm that you can see the verified Login, the accounts you selected and the symbol finder.

TradingView alert configuration
6
Create a new strategy

Create a strategy by clicking on the new strategy button and enter the strategy name.

TradingView alert configuration
7
Configure accounts and verify connection

Enter the login, account and symbol data. You can find the symbol in the upper search box. Clicking on the "Verify connection" button will show you a success message indicating that the connection has been correct.

TradingView alert configuration
8
Check the connection

If everything went well, you will see a green check mark in the strategy tab accompanied by the symbol you selected.

TradingView alert configuration
9
Starts the server

Start the server with the "Start Server" button. That's it! You can now receive TradingView signals in your cTrader account.

TradingView alert configuration
10
Copy the Webhook URL and strategy JSON

Copy the URL shown in the "Webhook URL" field from TradingView to cTrader and the JSON of the strategy with the "Copy JSON" button.

TradingView alert configuration
11
TradingView Alert

Create an alert in TradingView and in the "Webhook URL" field in the "Notifications" section, paste the URL you copied.

TradingView alert configuration
12
JSON TradingView Alert

In the "Message" field of the "Configuration Options" section you must paste the JSON of the strategy.

TradingView alert configuration

MT4 to MT5

Create a new connection

Enter the login, password, server and terminal of your MT5 account.

Install our EA in MT4

Click on the "Install EA" button and select the MT4 terminal.

Configure the EA

Configure and activate the EA inside your MT4 terminal in the symbol of your choice.

Verify the connection

Verify the connection by clicking on the "Verify connection" button.

Starts the server

Start the server with the "Start Server" button. Your MT4 trades will be copied to your MT5 account.

Note: Your credentials are stored securely and only on your local computer.
1
Create a new connection

Go to the "MT4 to MT5/MT4" section. Create a new MT5 connection and enter the source MT4 terminal and the credentials of the target MT5 account.

MT5 credentials configuration
2
Install the EA in MT4

Click on the "Install MT4 Source EA" button to install the EA in your MT4 terminal automatically.

TradingView alert configuration
3
Configure the EA

Check that the EA "TradingView_MT4_to_MT4_Tradingpinelab" is installed on your MT4 terminal, it should appear in the "Expert Advisors" section.

TradingView alert configuration
4
Configure MetaTrader 4 Options

Open the "Tools" menu and select "Options". You can also press Ctrl + O to open the options menu.

TradingView alert configuration
5
Allow web requests

In the "Expert Advisors" section you must check the "Allow WebRequest for the following URLs" checkbox and add the following URL: http://127.0.0.1

TradingView alert configuration
6
Add EA to any symbol

We add the EA to any symbol to start copying your trades from MT4 to MT5.

TradingView alert configuration
7
Verify connection

Click on the "Verify connection" button to verify that the data is correct and there is a connection to the terminals. Remember that the MT4 terminal must be open and with the EA installed and active.

MT4 connection verification
8
MT5 account connected

If the verification is successful, the created account will appear with a green check and will be ready to trade.

Server startup
9
Starts the server

We start the server with the "Start Server" button. Your MT4 trades will be copied to your MT5 account.

TradingView alert configuration
Important: each terminal must have only 1 account connected. If you want to connect more than one account, you must duplicate the terminal and associate the new account to that terminal.
Important: you must have "Algorithmic Trading" enabled in your MetaTrader 5 terminal and added the URL http://127.0.0.1 in the MT4 Source terminal under "Allow WebRequest for the following URLs".
MT5 Configuration

MT4 to MT4

Install our EA in MT4 ORIGEN

Click on the "Install EA" button and select the MT4 terminal.

Install our EA in MT4 DESTINO

Click on the "Install EA" button and select the MT4 terminal.

Configure the EA on both terminals

Configure and activate the EA inside your MT4 terminal on the symbol to be traded.

Starts the server

Start the server with the "Start Server" button. Your MT4 trades will be copied to your MT4 account.

Note: Your credentials are stored securely and only on your local computer.
1
Create Connection

Go to the "MT4 to MT4/MT5" section and create a new Metatrader 4 type connection.

MT5 credentials configuration
2
Install EA Origin

Click the "Install Source EA" button and select the source terminal.

MT4 connection verification
3
Install EA Destination

Click the "Install Target EA" button and select the target terminal.

Server startup
4
Configure Options in the MT4 Source terminal

Open the "Tools" menu and select "Options". You can also press Ctrl + O to open the options menu.

TradingView alert configuration
4.1
Allow web requests

In the "Expert Advisors" section you must check the "Allow WebRequest for the following URLs" checkbox and add the following URL: http://127.0.0.1

TradingView alert configuration
5
Configure Source EA

Configure the Expert Advisor in the source terminal. Refresh Expert Advisors and activate the Expert Advisor "MT4_TO_MT4MT5_Tradingpinelab" by dragging the Expert Advisor to the chart. (You can check that it starts correctly in the Experts tab, where the port is assigned).

TradingView alert configuration
6
Configure EA Destination

Configure the Expert Advisor on the target terminal. Refresh Expert Advisors and search for the Expert Advisor "TradingView_MT4_to_MT4_Tradingpinelab".

TradingView alert configuration
6.1
Adds the EA to any symbol

Add the EA to any symbol you want to trade, the higher the number of ticks the better. Remember to check the "Allow DLL import" and "Allow automatic trading" options.

MT4 connection verification
7
Verify the connection

Click on the "Verify Connection" button to save the connection and verify that there is a connection to the MetaTrader 4 terminals.

TradingView alert configuration
8
Starts the server

Start the server with the "Start Server" button.

TradingView alert configuration
9
Ready!

Your MT4 trades will be copied to your MT4 account using the created connections.

TradingView alert configuration
Important: each terminal must have only 1 account connected. If you want to connect more than one account, you must duplicate the terminal and associate the new account to that terminal.
Important: you must have "Algorithmic Trading" enabled in your MetaTrader 4 terminal and added the URL http://127.0.0.1 in the MT4 Source terminal under "Allow WebRequest for the following URLs".
MT5 Configuration

MT5 to MT5

Install our EA in MT5 ORIGIN

Click on the "Install EA" button and select the MT5 terminal.

Configure the EA on the source terminal

Configure and activate the EA inside your MT5 terminal.

Verify the connection

Enter the credentials in both MT5 accounts and verify the connection.

Starts the server

Start the server with the "Start Server" button. Your MT5 trades will be copied to your MT5 account.

Note: Your credentials are stored securely and only on your local computer.
1
Create Connection

Go to the "MT5 to MT5/MT4" section and create a new Metatrader 5 connection. Select the source terminal and the destination terminal.

MT5 credentials configuration
2
Install EA Origin

Click the "Install Source EA" button and select the source terminal.

MT4 connection verification
3
Configure MetaTrader 5 Options

Open the "Tools" menu and select "Options". You can also press Ctrl + O to open the options menu.

TradingView alert configuration
3.1
Allow web requests

In the "Expert Advisors" section you must check the "Allow WebRequest for the following URLs" checkbox and add the following URL: http://127.0.0.1

TradingView alert configuration
4
Configure Source EA

Configure the Expert Advisor in the source terminal. Refresh Expert Advisors and activate the Expert Advisor "MT5_TO_MT4MT5_Tradingpinelab" by dragging the Expert Advisor to the chart. (You can check that it starts correctly in the Experts tab, where the port is assigned).

TradingView alert configuration
5
Verify the connection

Click on the "Verify Connection" button to save the connection and verify that there is a connection to the MetaTrader 5 terminals.

TradingView alert configuration
6
Starts the server

Start the server with the "Start Server" button.

TradingView alert configuration
7
Ready!

Your MT5 trades will be copied to your MT5 account using the created connections.

TradingView alert configuration
Important: each terminal must have only 1 account connected. If you want to connect more than one account, you must duplicate the terminal and associate the new account to that terminal.
Important: you must have "Algorithmic Trading" enabled in your MetaTrader 5 terminal and added the URL http://127.0.0.1 in the MT5 Source terminal under "Allow WebRequest for the following URLs".
MT5 Configuration

VPS

Login to your VPS

Login to your VPS with your username and password

Install Trading Pine Lab

Install Trading Pine Lab and the required applications on your VPS

Operate without worrying about your connection!

Pine Lab Trading alerts are automatically executed in your MT4/MT5 account.

Note: it is recommended to change the Windows password when logging in for the first time.
1
Access your VPS

Click on the "Access Server" button from VPS and you will be redirected to the login.

Access the server
2
Log in to Guacamole

Use the credentials of your VPS indicated in the "Guacamole Credentials" section to log in to Guacamole.

Login with Guacamole
3
Log in to Windows

Use the credentials received by mail to log on to Windows.

Log on to Windows
4
Install Trading Pine Lab

Install MetaTrader 5/4 and the necessary applications on your VPS.

Install Trading Pine Lab
5
Configure the application

Configure your strategies in Trading Pine Lab and... You're done! You can now trade without worrying about your connection.

Configure VPS

Strategies

Our algorithmic strategies have been developed, tested and optimized to deliver real performance in multiple markets.

How to Obtain Strategies?

1
Subscribe to Trading Pine Lab

By subscribing to our service, you will receive access to all our premium strategies.

2
TradingView User

Your TradingView user will have direct access to all strategies.

3
Add Strategy to your Graphics

Click on "Add to Chart" in TradingView, search for our strategies and add one to your charts.

Main Features

  • Reversal, breakout, momentum and scalping strategies
  • Customizable parameters according to your risk profile
  • Ideal for anchor accounts
Note: Strategies are shared directly in TradingView to ensure security and access control.
Important: The source code of the strategies is not available to protect our intellectual property.

Common MetaTrader 5 Errors

Code Description Solution
Connection Errors
-6 Incorrect credentials Verify your username and password. If it persists, contact your broker.
-7 Error connecting to the server Check your internet connection and that the broker's server is operational.
-8 Request rejected by server Try again in a few minutes. If it persists, contact support.
Initialization Errors
-10000 Internal terminal error Restart MetaTrader 5. If it persists, reinstall the application.
-10003 MetaTrader 5 is not installed Install MetaTrader 5 from your broker's official website.
-10004 Error verifying credentials Verify your credentials and make sure you have trading permissions.
Trading Errors
10011 Error processing the request Verify the order parameters and try again.
10019 Not enough money Check your balance sheet and the margin required for the operation.
10021 No quotes available Wait until the market is active or check the availability of the symbol.
Market Mistakes
10018 Market closed Wait until the market is open to trade.
10020 Prices changed Prices have changed, please update and try again.
10029 Order or frozen position Wait for it to thaw or contact your broker.
Limit Errors
10033 Limit of pending orders Close some pending orders before opening new ones.
10034 Volume limit reached Reduce the position size or close some positions.
10040 Limit of open positions Close some positions before opening new ones.
Rules Errors
10042 Long positions only The instrument only allows buy positions.
10043 Short positions only The instrument allows only sell positions.
10045 FIFO rule required Closes the positions in the order in which they were opened.
Trading Pine Lab

Trading Pine Lab

Assistant available

Welcome to Trading Pine Lab! I am your assistant specialized in algorithmic trading solutions.

How can I help you?

Ahora