How to Export MT4 Account History in Three Ways
In MetaTrader 4, open the Terminal (Ctrl+T), select the Account History tab, right-click, choose a period such as All History, then pick Save as Report or Save as Detailed Report. Both save an HTML file. To get the data into a spreadsheet, open the HTML in a browser and copy the table, or use a conversion script. Check the time zone and remove balance rows.
- MT4's built-in export is an HTML file: Save as Report for the standard version, Save as Detailed Report for the version with extra parameters.
- Choose All History before you save; the default view may show only a recent period.
- The platform does not give you a native CSV of trades, so the usual route to a spreadsheet is copying the table from the HTML file.
- Balance rows (deposits and withdrawals) sit in the same table as trades and must be removed before you calculate win rate or profit factor.
- Timestamps follow the broker's server time in the sources I read, not your computer's clock, so test one trade before you import.
In this article
- What are the three ways to export MT4 history?
- How do I use Save as Report, step by step?
- What does the MT4 history table contain?
- How do I get MT4 history into Excel or Google Sheets?
- What are the time-zone and balance-row gotchas?
- How do I check that the export is complete?
- A monthly routine that takes ten minutes
- Which method should you pick for a journal?
- Mistakes to avoid when exporting MT4 history
- The short version
You export MT4 trade history from the Account History tab of the Terminal. Press Ctrl+T, open the tab, right-click, choose All History, and then choose Save as Report or Save as Detailed Report. MT4 saves an HTML file. It has no one-click CSV, so getting the trades into a spreadsheet takes one more step, and that step is where most journals pick up errors.
Below are the three methods compared on completeness, then the two gotchas that distort statistics more than any menu mistake: time zones and balance rows. I have kept to what MetaTrader 4’s own help page confirms, and I flag what comes from third-party guides or varies by broker build.
What are the three ways to export MT4 history?
The three ways are the standard report, the detailed report, and a copy of the table into a spreadsheet. The first two are built in and produce HTML. The third turns that HTML into rows you can sort and import.
| Method | Output | Completeness | Best for |
|---|---|---|---|
| Save as Report | HTML | Closed trades, open trades and pending orders listed, plus a summary | Quick record, sharing |
| Save as Detailed Report | HTML | Same plus an additional set of parameters | Review, statistics |
| Copy to spreadsheet | Your own CSV or XLSX | Only what you copy | Journals, custom analysis |
MetaTrader 4’s help page says Save as Report saves the account history “in the form of the HTML file,” and that a detailed report “differs from a normal one for an additional set of parameters.” It does not list what those parameters are, and third-party guides describe them differently, so do not rely on a specific extra statistic being present. Save one of each and open them side by side.
How do I use Save as Report, step by step?
Open the Account History tab, set the period, right-click and save. The steps match MetaTrader’s help and a third-party walkthrough.
- Press Ctrl+T to open the Terminal, then click Account History.
- Right-click in the list. Choose All History. Other options are Last 3 Months, Last Month and Custom Period, where you enter From and To dates.
- Right-click again and choose Save as Report (or Save as Detailed Report).
- Make sure the file type is HTML, pick a location and name, and save.
- Open the file in a browser and scroll to the end to confirm the last trade is there.
Pick All History first. MetaTrader 4’s help states that the Last 3 Months and Last Month views show only recent history, filtered by close time, so a report saved from one of them silently omits older trades. If the tab looks short, the period filter is the first thing to check.
What does the MT4 history table contain?
The table lists, left to right: Order (the ticket number), open time, Type, Size, Symbol, open Price, S/L, T/P, close time, close Price, Commission, Taxes, Swap, Profit and Comments, according to the same help page. Commission, Taxes and Comments can be shown or hidden from the right-click menu.
The report separates closed trades, open trades and pending orders, and its summary shows Balance, Equity, Margin and Free Margin. For a journal you want the closed-trades block only. Open trades have no final result yet, and pending orders are not trades.
A few terms worth defining. Ticket is the unique order number, and it is your best key for avoiding duplicates. Swap is the overnight financing charge or credit. Type can be buy, sell, or balance, which marks funds entering or leaving the account and is not a trade.
How do I get MT4 history into Excel or Google Sheets?
Open the saved HTML in a browser, select the trade rows, copy them and paste into a spreadsheet. This is the manual route that both the forex.in.rs guide and users on an MQL5 forum thread describe.
One forum user reported that opening the HTML in Firefox and selecting only the transaction rows worked well, while another said a CSV export they tried inserted a line feed before the end of each trade’s data, which scrambled rows. That thread is old, so treat it as a warning to inspect the result rather than as a current bug report.
After pasting, do four checks: delete the header and summary rows, make sure each trade is on one row, change the date column to a real date type, and save as CSV. If your spreadsheet opens CSV files in one column or swaps commas and semicolons, see the CSV import errors guide. A script can automate the conversion, and the guide I read mentions one placed in the MQL4 Scripts folder, but I could not verify that script, so run any third-party script on a demo account first.
What are the time-zone and balance-row gotchas?
MT4 timestamps are written as YYYY.MM.DD HH:MM, and the help page does not name a time zone. The forex.in.rs guide says they reflect the broker’s server time rather than your PC’s local time. Test it on one trade you remember.
Here is a hypothetical example. Suppose your broker’s server runs at UTC+2 and a row shows a close at 2026.01.13 00:30.
| Step | Value |
|---|---|
| Server time shown | 2026.01.13 00:30 |
| Convert to UTC (subtract 2 hours) | 2026.01.12 22:30 |
| Convert to New York, assuming UTC-5 | 2026.01.12 17:30 |
The trade belongs to January 12 for a New York trader, but your file says January 13. Import it unchanged and your daily profit and loss, your session analysis and your forex session timing all shift. Many journals let you set the file’s time zone at import, which is the clean fix.
Balance rows cause the second distortion. Hypothetical closed trades: +120, -60, +90, -40. That is 2 wins from 4 trades, a 50% win rate, and a net of +110. If a +1,000 deposit row stays in the table, the profit column sums to +1,110 and the win rate reads 3 of 5, or 60%. Neither number is true.
How do I check that the export is complete?
Reconcile the file against your account before you trust it. The test is simple: the sum of every closed trade’s profit, commission and swap, plus deposits and minus withdrawals, should equal the change in your balance over the same period. If it does not, rows are missing or duplicated.
Hypothetical example with round numbers. You started the period with a balance of 5,000 and deposited 1,000. The table shows four closed trades.
| Trade | Profit | Commission | Swap | Net |
|---|---|---|---|---|
| 1 | +120 | -4 | 0 | +116 |
| 2 | -60 | -4 | -2 | -66 |
| 3 | +90 | -4 | 0 | +86 |
| 4 | -40 | -4 | -1 | -45 |
Net of the four trades: 116 - 66 + 86 - 45 = +91. Expected ending balance: 5,000 + 1,000 + 91 = 6,091. If your platform’s balance reads 6,091, the export is complete. If it reads 6,151, there is a 60 difference, and you should look for a missing trade of about that size, a trade dated just outside your period, or a withdrawal row you dropped.
Two further checks take a minute. Count the closed trades in the file and compare with a rough memory of how many you took. Then scan the tickets for duplicates, because a ticket number appearing twice means a row was pasted twice. Spotting this early is much cheaper than finding a distorted equity curve three weeks later.
A monthly routine that takes ten minutes
Exporting is easy to forget, and the day you need an old file is the day it is missing. Put a recurring reminder on the first trading day of each month and run the same short routine every time.
- Open Account History, choose All History and save a Detailed Report named with the date, for example
mt4-2026-12-01-detailed.html. - Copy the closed-trades table into your working sheet or import file.
- Delete balance rows, then reconcile the ending balance as shown above.
- Record the server-time offset you used, so next month’s file is treated the same way.
- Store the HTML in a folder that is backed up, and never edit it.
Doing this monthly also keeps the pasting job small. A month of trades is a short table, while a year pasted at once is where line breaks and duplicates hide. If you trade several accounts, repeat the routine per account and add the account number to the filename, because ticket numbers are assigned per account.
Which method should you pick for a journal?
Use the detailed report if you want a record you can read, and use the spreadsheet copy if you want a file a journal can import. Often you need both: the HTML as your archive, the CSV as your working copy.
Keep the original HTML untouched. Broker servers keep your history, and the guide I read says users cannot delete it from the server, but platform builds and broker policies change, so your own file is the safest copy. If you also trade MT5, the layout is different, and the MT5 export guide covers the Positions, Deals and Orders views. Spreadsheet users who are weighing the effort of pasting every month can compare it with software in the spreadsheet versus journal software breakdown.
If you would rather not paste tables, a journal such as Pips Decoded recognizes MT4 CSV layouts and lets you set the file’s time zone at import; details and plan limits are at pipsdecoded.com.
Mistakes to avoid when exporting MT4 history
| Mistake | What happens | Fix |
|---|---|---|
| Exporting Last Month only | Older trades missing | Choose All History |
| Leaving balance rows in | Win rate and profit factor wrong | Delete rows of type balance |
| Ignoring server time | Trades land on the wrong day | Convert or set the file time zone |
| Counting open trades | Floating profit mixed with results | Keep the closed-trades block only |
| Overwriting the original | No way to recheck | Save the HTML and work on a copy |
This article is educational and is not financial advice.
The short version
- Account History tab, right-click, All History, then Save as Report or Save as Detailed Report.
- The output is HTML; for a spreadsheet, copy the table and save as CSV, then inspect the rows.
- Remove balance rows and keep closed trades only.
- Treat timestamps as server time until you prove otherwise with one known trade.
- Menus can differ by broker build; the principle is a full-period report saved untouched.
Sources
Frequently asked questions
How do I export my account history in MT4?
Press Ctrl+T to open the Terminal, click the Account History tab, right-click the list and choose All History, then right-click again and choose Save as Report or Save as Detailed Report. Pick a folder and save the HTML file. Open it in a browser to check it before you use it.
Can MT4 export trade history to CSV or Excel?
MetaTrader 4's built-in export saves HTML, not CSV. The common workaround is to open the HTML report in a browser, copy the trades table and paste it into a spreadsheet, then save as CSV. Community scripts can also convert the report. Review the pasted rows for broken line breaks.
What is the difference between Save as Report and Save as Detailed Report in MT4?
Both save the account history as an HTML file. MetaTrader's help says the detailed report differs from the normal one by an additional set of parameters. Third-party guides describe extra statistics such as a balance curve. Save both once and compare, because the exact extras can depend on the build.
Why does my MT4 history show only recent trades?
The Account History tab filters by period, and the right-click menu offers All History, Last 3 Months, Last Month and Custom Period. If you see only recent trades, a shorter period is selected. Choose All History, then export. Your broker may also limit how much history the server returns.
What time zone are MT4 history times in?
MetaTrader's help page lists times in YYYY.MM.DD HH:MM format without naming a time zone. A broker-neutral guide I read says they follow the broker's server time, not your PC clock. Compare one trade with your own record to find the offset before importing.
Keep reading
How to Export Your MT5 Trade History (CSV and HTML), Step by Step
How to export MT5 trade history from the Toolbox History tab, which view to pick (Positions, Deals or Orders), and the date-range trap that drops trades.
Trade CSV Import Errors: Time Zones, Commas, Duplicates Fixed
Fix the ten most common trade CSV import errors: delimiters, thousand separators, repeated Time and Price columns, balance rows, time zones and duplicates.
Spreadsheet or Journal Software? An Honest Cost-and-Time Comparison
Trading journal Excel vs software, with the arithmetic: minutes per trade, trades per month and the value of your time against a subscription price.
Forex Trading Sessions in Your Time Zone: Tokyo, London, New York
Forex trading sessions in UTC, how daylight saving moves the London and New York overlap, a method to convert to your time zone, and how to log session.
Written by the Pips Decoded editorial team and last updated November 13, 2026. We cite the sources we opened and recompute every example. Pips Decoded sells a trading journal, so read our product mentions with that in mind. How we write and check articles. This article is educational and is not financial advice.