To export MT5 history to Excel, open the desktop terminal’s Toolbox with Ctrl+T, select History, set the date range, then right-click and choose Report > Open XML (MS Excel). In Excel, use Save As to make an .xlsx copy. This creates a readable account-history report for review and analysis; the exact sections depend on the history period and report options available in your MT5 build.
What You’ll Need
- MetaTrader 5 desktop, signed in to the trading account whose history you need. The broker’s server determines which account records are available.
- Microsoft Excel desktop is recommended for opening MT5’s XML report and saving it as an .xlsx workbook. Excel for Microsoft 365 on Windows is used in the instructions below.
- A date range in mind. If you need a particular month, quarter, or custom span, decide the start and end dates before exporting.
- Enough account access to view the relevant history. If records are missing from MT5, Excel cannot restore them; ask the broker whether older data is available.
Step-by-Step
- Open the Toolbox. In MT5 for Windows, press Ctrl+T or choose View > Toolbox. The Toolbox appears along the bottom of the terminal. Select the History tab. If the Toolbox is already open but History is hidden, look along its tab row; you may need to widen the panel or use the tab navigation controls. On macOS, use the terminal’s View menu to show the Toolbox, then select History; menu labels and shortcuts can vary between Mac distributions.
- Choose the records and period you want. Right-click in the History area and pick an available period, such as All History, Last Month, Last 3 Months, or Custom Period. For a defined date range, choose Custom Period and enter the beginning and ending dates in the dialog, then confirm. Check both dates carefully: an end date that is too early can omit the final day’s activity, while choosing All History may include years of transactions you do not need. The available preset names can vary slightly by terminal version.
- Decide whether you need deals or orders. MT5 distinguishes deals (executed transactions) from orders (instructions placed, changed, or cancelled). If the History context menu offers Deals and Orders display options, choose the view that answers your question before creating the report. Use deals when you want executed activity such as entries, exits, volume, and profit; use orders when you need the order lifecycle. A report may include several account sections, so inspect its contents rather than assuming every line is an executed trade.
- Create the Excel-compatible report. Right-click inside the History area again and point to Report. Choose Open XML (MS Excel). MT5 generates an XML-format report and attempts to open it using the associated application. If Excel is installed and associated with the report, it should open there. This is not necessarily a plain CSV export: the report can be formatted and may contain account details, totals, and transaction tables. The appearance and sections can differ with MT5 versions and broker-provided account data.
- Save a separate Excel workbook. In Excel, inspect the report first, then select File > Save As. Choose a folder you can find again, enter a descriptive filename, and set the file type to Excel Workbook (*.xlsx). Select Save. If Excel warns that some features or formatting may not be preserved, read the message: the MT5 source is XML, while .xlsx is Excel’s workbook format. Saving a new .xlsx copy keeps the original report available and gives you a convenient file to sort, annotate, and work with. On Mac, use File > Save As and choose Excel Workbook if that format is offered.
- Check the exported content against MT5. Compare the report’s account identifier, selected date span, and a few visible transaction details with the History tab. Check that the first and last dates make sense and that totals or profit figures are present where expected. If you were looking for deal-level rows but see only a summary, return to MT5 and check the selected history view and report output. Do not use a summary total as a substitute for individual transactions when you need transaction-level analysis.
- Keep the source and working copy distinct. Store the generated report and the .xlsx workbook in a clearly named folder, or retain the original report separately if MT5 created one on disk. Add the account nickname and date range to the workbook filename, not sensitive login details. For example, a name such as AccountA_History_2026-01_to_2026-03.xlsx is easier to identify later than Report1.xlsx. Avoid editing the only copy if you may need to compare it with the original export.
Common Mistakes
Exporting the wrong date range: A preset such as Last Month may mean the previous calendar month, not the last 30 days. Use Custom Period when the reporting dates must be exact, and confirm the terminal’s displayed range before exporting.
Confusing orders with deals: An order can be placed without being filled, while a deal represents an execution. Depending on the view and report, cancelled or unfilled orders may not appear as executed activity. Choose the relevant history category and explain that distinction if you share the workbook.
Expecting a CSV file: Open XML (MS Excel) creates an XML-based report, not necessarily a flat CSV table. The report can be readable in Excel but include headings, account information, and summaries alongside activity. If you need a simple table for another system, check whether the report provides the needed rows before relying on it as a data feed.
Overwriting the original or saving in the wrong format: An XML report and an .xlsx workbook are different file types. Use Save As to create an Excel Workbook copy and check the filename extension and selected file type before confirming. Changing a file’s extension by renaming it does not convert its contents.
Assuming missing history is an Excel problem: Excel only displays what MT5 exported. A blank range, incomplete account record, or broker retention limit must be addressed in MT5 or with the broker; reformatting the workbook will not add missing transactions.
Tips
- Export one date range at a time when you are preparing a monthly record. It is easier to verify smaller exports and spot a missing month than to inspect a very long report.
- Keep the report’s displayed date and time information intact when first saving it. MT5 and Excel may present timestamps according to different time-zone or regional settings; do not assume a displayed time is local time without checking the broker’s convention.
- When reviewing figures, distinguish balance, equity, credit, and profit fields. They describe different account values and are not interchangeable. Keep the original report for reference if you plan to add your own calculations or notes.
- For a workbook you will share, remove or protect account identifiers and other private details that are not needed by the recipient. History reports can contain more account information than a simple list of trades.
- If you want to analyze the data in Excel, make a working copy first. Check whether each column is stored as a date, number, or text before sorting or filtering; imported XML data may not behave exactly like a hand-built Excel table.
- On Windows, Ctrl+T opens MT5’s Toolbox. Excel keyboard shortcuts are not required for the export; use the menus if you are unsure which window currently has focus. On Mac, keyboard shortcuts differ, so the View menu in MT5 is the safer way to show the Toolbox.
Troubleshooting
History is empty or older trades are missing. Confirm that the correct trading account is active, then right-click History and try All History or a wider Custom Period. Allow the terminal to connect and load account data. If the broker does not provide the requested older records, contact its support team and ask whether it can supply an account statement or historical report.
There is no Report option or the expected XML choice. Make sure you are right-clicking inside the History tab rather than the Trade tab or a chart. Check that MT5 is the desktop terminal and that the Toolbox is showing the account history. Update or restart the terminal if its interface appears incomplete. Some menu labels and options vary by version; if the option remains unavailable, check the platform’s current help information or ask the broker about its MT5 build.
The report opens in a browser, text editor, or another application. The report is XML, and Windows uses the file association to decide which application opens it. If the report was saved to disk, open Excel and use File > Open to browse to it; if necessary, change the file picker filter to show XML files. Do not rename the XML file to .xlsx. Once Excel has opened and displayed the report, use File > Save As to create an actual Excel Workbook.
Excel shows unreadable text or asks how to import the file. Confirm that you selected Open XML (MS Excel) in MT5 and that you are opening the generated report, not a different terminal file. In Excel desktop, use File > Open to select the XML report and follow any import prompt. Excel for the web may not handle every MT5 XML report in the same way as desktop Excel; download the file and open it in desktop Excel if the layout is unclear.
The workbook has no individual transaction rows. A report can emphasize account totals or show a different history category than you expected. Return to MT5, check the period and Deals or Orders view, then generate the report again. If the report still does not provide the detail you need, ask the broker whether it offers a detailed statement export. Do not infer individual trades from a combined total.
Frequently Asked Questions
Can MT5 export history directly as an Excel file?
MT5’s Report > Open XML (MS Excel) option creates an Excel-compatible XML report. Open it in Excel and save it as .xlsx for a standard Excel workbook. It is not the same as exporting a native .xlsx file directly from the History tab.
Can I export only one month?
Yes. In the History tab, right-click, choose Custom Period, set the start and end dates for the month, and generate the report. Check the report dates afterward, especially if you need a particular time zone or an exact month boundary.
Does the report include all trades and orders?
Not necessarily in the same way. MT5 separates executed deals from orders, and the report’s sections depend on the selected period, view, and account data. Choose the relevant category and check the output before treating it as a complete transaction ledger.
Can I open the MT5 report in Excel for the web?
Excel for the web may not display every XML report as expected. The most dependable workflow is to open the report in Excel desktop, save it as .xlsx, then store or upload that workbook for use online.
Why are some older transactions missing?
The terminal can show only history made available for the account, and the broker may limit how far back it supplies records. Try All History and confirm you are in the right account; if records remain unavailable, ask the broker for an older statement.
Related
- How to Do Superscript in Excel with a Shortcut
- How to Format Subscript Numbers in Microsoft Excel
- Quick Average in Excel: A Fast Way to Find the Mean
Try it: the Date Difference Calculator: days, months, years and weekdays between two dates, with the DATEDIF formulas.
More in How-to basics
- Excel Table Repeat Header Row: What You Can DoExcel tables do not have a setting that repeats their header row on every printed page. To print…
- Python pandas Excel Merge: Join Workbooks and SheetsTo merge Excel data with Python, read each worksheet into a pandas DataFrame with pd.read_excel(), then use pd.merge()…
- Excel Remove Circular Reference Warning: What to DoTo remove Excel’s circular reference warning, find and correct the formula that refers to its own cell, either…
- Lock Cells in Google Sheets: Protect Formulas from EditsTo stop editors changing formula cells in Google Sheets, select the cells, choose Data > Protect sheets and…
- Excel Bucket List Template: Plan and Track Your GoalsAn Excel bucket list template is a worksheet for recording experiences you hope to have, then organizing and…
- How to Find Power Query in Excel and Open the EditorIn Excel for Microsoft 365 on Windows, open the Data tab and choose Get Data to find Power…
Sources: Function behaviour and menu paths: Microsoft Support documentation for Excel. Method & sources
Spotted an error in this guide? Let us know.