Blog Details

thumb
01 Oct 2026

EX4 to MQ4 Decompiler Online: Source Code Recovery GuideS

EX4 to MQ4 Decompiler Online: Source Code Recovery Guide

If you have an EX4 file from MetaTrader 4 but no longer have the original MQ4 source code, you may be looking for an EX4 to MQ4 decompiler online.

The goal is usually straightforward: recover source-code information from a compiled MT4 application so it can be inspected, maintained, or potentially rebuilt.

However, EX4 to MQ4 recovery is not the same as uploading a file and performing an ordinary format conversion.

An EX4 is a compiled MQL4 application, while MQ4 is source code used during development. MetaQuotes introduced major changes to MQL4 and its compiler with MT4 Build 600 in 2014, including a revised language, unified compiler, changed file structure, and substantially revised protection for new EX4/EX5 files. (MetaQuotes)

This guide explains what online EX4 to MQ4 recovery means, how the process generally works, what information you should provide, what can affect the result, and what to check before using recovered source code.

What Is an EX4 to MQ4 Decompiler Online?

An EX4 to MQ4 decompiler online generally refers to an online tool or service that accepts an EX4 file for technical analysis and attempts to reconstruct MQL4 source-code information.

The important word is attempts.

A compiled EX4 is not simply a different document format from MQ4.

The normal development process works in the opposite direction:

MQ4 source → compiler → EX4 application

Source recovery attempts to analyze the compiled application and reconstruct usable source information.

That means the result can depend heavily on the individual EX4.

EX4 vs MQ4

Before using an online recovery service, it helps to understand the two file types.

File

Purpose

MQ4

Editable MQL4 source code

MQH

Supporting MQL4 source/include file

EX4

Compiled MQL4 application

DLL

External Windows library that may be used by an application

MetaQuotes documents that MQL4 programs can include Expert Advisors, indicators, scripts, and libraries, with EX4 files being used as compiled applications. (MetaQuotes)

MQ4

MQ4 is what developers normally edit.

For example:

MyExpertAdvisor.mq4

can contain the source code responsible for the EA’s trading logic.

EX4

After compilation, the program can become:

MyExpertAdvisor.ex4

The EX4 is intended to run in MetaTrader 4.

It is not simply an MQ4 file with a different extension.

Can You Simply Rename EX4 to MQ4?

No.

Changing:

MyEA.ex4

to:

MyEA.mq4

does not recover the original source code.

The contents of the file remain compiled program data.

An actual recovery process is fundamentally different from renaming the extension.

Why People Search for EX4 to MQ4 Online Services

There are several situations where someone may have a legitimate reason to investigate an EX4.

Lost source code

You may have accidentally deleted the original MQ4 file.

Old Expert Advisor

You may have an EA that has been running for years but the original developer is no longer available.

Legacy indicator

A company may still depend on an old indicator without having the development source.

Software maintenance

You may need to understand or modify an existing MT4 application.

Development migration

You may need to investigate an old application before rebuilding or updating it.

The important point is that having the EX4 does not automatically mean you have the original MQ4 project.

How Does Online EX4 Source-Code Recovery Work?

The exact process varies between providers, but a typical technical workflow can involve several stages.

1. File submission

The EX4 is provided for assessment.

The original file should be preserved separately before submission.

2. File identification

The application may be identified as an:

  • Expert Advisor
  • Custom indicator
  • Script
  • Library

3. Technical assessment

The file can be examined to determine its general structure, compiler generation, dependencies, and other characteristics relevant to the requested recovery.

4. Source reconstruction

Where technically appropriate, recoverable program information may be reconstructed into an editable source representation.

5. Compilation

The resulting source can be tested in MetaEditor to determine whether it compiles and what dependencies may be missing.

6. Functional testing

If the original EX4 still works, its behavior can be compared with the reconstructed version.

This final stage is particularly important for Expert Advisors and indicators.

Why MT4 Build History Matters

MetaTrader 4 has changed considerably over its lifetime.

One of the most important milestones was Build 600, released in February 2014.

MetaQuotes stated that Build 600 introduced a substantially revised MQL4 language and a unified compiler/MetaEditor environment. It also introduced changes to the MQL4 file structure and significantly revised protection for new EX4/EX5 applications. (MetaQuotes)

This means an older EX4 and a newer EX4 should not automatically be treated as technically identical.

Old EX4 Applications

MetaQuotes documented that older MQL4 applications could be copied to the newer terminal during the Build 600 transition without being automatically recompiled. (MQL5)

This is important because the MT4 terminal you use today does not necessarily tell you which compiler created your EX4.

Does My Current MT4 Build Identify My EX4?

No, not necessarily.

Suppose your current MT4 terminal is a modern build.

That tells you about the terminal currently installed.

It does not automatically establish the compiler build used to create:

OldEA.ex4

The EX4 could have been compiled years earlier and then copied to your current terminal.

When evaluating source-code recovery, the file’s history can therefore be useful.

What Can Affect EX4 to MQ4 Recovery?

There is no single result that applies to every EX4.

Several factors can affect the technical assessment.

Compiler generation

An older EX4 may have been produced using a different MQL4 compiler environment from a newer application.

Protection

MetaQuotes introduced substantially revised protection for new EX4/EX5 applications with Build 600. (MetaQuotes)

Program complexity

A simple indicator and a large multi-component Expert Advisor are very different projects.

Dependencies

An application may rely on:

  • EX4 libraries
  • MQH files
  • DLLs
  • Configuration files
  • Presets
  • External services

Desired result

There is a significant difference between:

  • Recovering readable source information
  • Producing compilable source
  • Reproducing behavior
  • Recreating the original development project

These should not be treated as identical goals.

Can Every EX4 Be Converted Perfectly?

No universal guarantee should be made.

The original MQ4 project may contain information that is not available in the same form in the compiled EX4.

For example, the original developer may have used:

  • Meaningful variable names
  • Detailed comments
  • Custom formatting
  • Multiple MQH files
  • Internal documentation
  • External libraries
  • DLLs

A recovered source representation may therefore differ from the original source even when important program logic can be reconstructed.

What About Modern EX4 Files?

Modern EX4 files require particular care when evaluating recovery claims.

MetaQuotes explicitly stated that the Build 600 generation introduced significantly revised protection for EX4 applications. (MetaQuotes)

Online community discussions contain different claims about what is possible with post-Build-600 EX4 files. Those discussions should not be treated as definitive technical proof.

The practical approach is to assess the specific file rather than assuming that every modern EX4 has the same outcome.

What Should You Send to an Online Recovery Service?

If you own the software or have authorization to have it analyzed, provide as much relevant information as possible.

The original EX4

Keep an untouched backup.

Related files

If available, gather:

  • MQ4 files
  • MQH files
  • EX4 libraries
  • DLL files
  • .set files
  • Configuration files

MetaQuotes’ documented MT4 structure separates Expert Advisors, indicators, scripts, include files, libraries, files, and presets into different locations, so supporting files can be relevant to understanding a project. (MetaQuotes)

Application information

Tell the provider whether the EX4 is:

  • An EA
  • Indicator
  • Script
  • Library

Historical information

Include:

  • Approximate date obtained
  • Original developer
  • Old MT4 version, if known
  • Current MT4 build
  • Where the file originally came from

How to Protect Your EX4 Before Uploading It

An EX4 can contain valuable commercial trading logic.

Before using an online service:

  1. Keep an untouched local backup.
  2. Check the provider’s file-handling policy.
  3. Understand whether files are retained.
  4. Ask who can access uploaded files.
  5. Avoid uploading files you are not authorized to share.
  6. Clarify whether the file is deleted after processing.

For proprietary EAs, confidentiality should be considered alongside technical capability.

What Should an Online EX4 Recovery Service Tell You?

Before paying for a service, ask clear questions.

1. Do you assess the actual EX4?

A file-specific assessment is preferable to a blanket promise.

2. What is the expected deliverable?

Ask whether you receive:

  • MQ4 source
  • Reconstructed source
  • Compilation support
  • Dependency analysis
  • Testing
  • Documentation

3. What happens if the source does not compile?

Find out whether corrections are included.

4. What happens if dependencies are missing?

This can be especially important for older EAs.

5. How are uploaded files handled?

Ask about storage, access, and deletion.

6. Are there technical limitations?

A transparent provider should explain that results can vary between EX4 files.

Online EX4 Recovery vs Local Analysis

There are two broad approaches.

Online service

The file is submitted to a remote provider.

Potential advantages:

  • Convenient
  • No technical setup
  • Specialist assessment
  • Possible testing support

Potential considerations:

  • File confidentiality
  • Upload requirements
  • Data retention
  • Third-party access

Local analysis

The file remains on your computer.

Potential advantages:

  • Greater control over the original file
  • No upload required
  • Useful for sensitive projects

Potential considerations:

  • More technical knowledge may be required
  • Software compatibility
  • Lack of specialist support

The appropriate option depends on the file, your technical requirements, and your confidentiality needs.

How to Test Recovered MQ4 Source Code

Never assume that receiving an MQ4 file means the project is finished.

Step 1: Compile it

Open the recovered source in MetaEditor.

Check for:

  • Compilation errors
  • Warnings
  • Missing includes
  • Missing libraries
  • Undefined functions

Step 2: Compare the original EX4

If the original still works, run controlled tests using identical:

  • Symbol
  • Timeframe
  • Inputs
  • Historical conditions

Step 3: Test an Expert Advisor

Check:

  • Entry conditions
  • Exit conditions
  • Stop-loss
  • Take-profit
  • Position sizing
  • Risk rules
  • Trading hours

Step 4: Test an indicator

Compare:

  • Signals
  • Values
  • Alerts
  • Chart objects
  • Multiple timeframes

Step 5: Use a demo account

For trading software, test the recovered application in a demo environment before considering live deployment.

Why Backtesting Matters for EAs

If the recovered EX4/MQ4 is an Expert Advisor, Strategy Tester can help compare behavior.

But backtesting should not be confused with proof of future profitability.

A recovered EA can produce different results because of differences in:

  • Spread
  • Slippage
  • Broker execution
  • Symbol specifications
  • Market conditions
  • Data quality
  • Trading rules

The initial goal should be to determine whether the recovered program behaves consistently with the original.

Common EX4 to MQ4 Online Mistakes

Mistake 1: Uploading the only copy

Always keep an original backup.

Mistake 2: Believing a file extension change is conversion

Renaming .ex4 to .mq4 does nothing to reconstruct source.

Mistake 3: Assuming the current MT4 build is the EX4 build

The application may have been compiled elsewhere.

Mistake 4: Ignoring dependencies

A main EX4 can depend on other files.

Mistake 5: Expecting identical source

Reconstructed code may not reproduce the original project exactly.

Mistake 6: Using recovered code immediately

Compile and test first.

Mistake 7: Ignoring authorization

Technical access does not automatically provide permission to reproduce another person’s software.

Frequently Asked Questions

What is an EX4 to MQ4 decompiler online?

It generally refers to an online service or tool intended to analyze an EX4 and reconstruct MQL4 source-code information.

Can I convert EX4 to MQ4 online?

Some services advertise EX4-to-MQ4 recovery, but the outcome depends on the individual EX4. It should not be treated as a guaranteed ordinary file conversion.

Can I convert EX4 to MQ4 for free?

Free tools may exist, but their capabilities, security, and reliability vary. Be particularly careful with confidential trading software.

Can every EX4 be recovered?

No universal guarantee applies to every EX4.

Does Build 600 matter?

Yes. Build 600 introduced major MQL4 and compiler changes and substantially revised protection for new EX4/EX5 applications. (MetaQuotes)

Is my current MT4 build the same as my EX4 compiler build?

Not necessarily.

Can an old EX4 still work on modern MT4?

MetaQuotes documented that old EX4 applications were copied during the Build 600 upgrade without automatic recompilation, and older programs could continue running in the newer terminal. (MQL5)

Will recovered MQ4 be identical to my original source?

Not necessarily. Reconstructed source can differ from the original development project.

Can an EA’s complete trading strategy be recovered?

The amount of logic that can be reconstructed depends on the individual application and available information. Do not assume that a recovered source file automatically represents every detail of the original development project.

Should I run recovered MQ4 on a live account?

No. Compile, inspect, compare, backtest where appropriate, and test on demo first.

Final Thoughts

An EX4 to MQ4 decompiler online is best understood as a source-code recovery option rather than a simple file converter.

The process begins with an EX4 compiled application and attempts to reconstruct usable source-code information. The result can depend on the EX4’s compiler generation, protection, structure, dependencies, and the specific recovery objective.

The Build 600 transition is particularly important because MetaQuotes introduced a substantially revised MQL4 environment and new protection for EX4/EX5 applications at that point. (MetaQuotes)

If you have lost the MQ4 source for an Expert Advisor, indicator, script, or library, the sensible workflow is:

Backup the original EX4 → identify the application → collect dependencies → provide file history → assess the EX4 → define the desired result → recover/reconstruct where appropriate → compile → test → validate.

Most importantly, choose a service based on transparent technical information rather than promises that every EX4 will produce a perfect copy of the original MQ4.

If the software is yours or you have authorization to work with it, a careful file-specific assessment is the best starting point.