A professional, cross-platform Java desktop application for analyzing your MetaTrader 5 trading performance. Import your trade history directly and visualize your edge with comprehensive analytics and beautiful UI.
- π Advanced Analytics: Real-time calculation of Win Rate, Profit Factor, Expected Value, Sharpe Ratio, and more
- πΉ Equity Curve: Visualize your account growth with dynamic equity curve and drawdown analysis
- π Period Analysis: Breakdown performance by Weekday, Hour, and Month with detailed charts
- π·οΈ Strategy Tagging: Tag trades by strategy/setup (e.g., "ORB", "Z-Score") to see what works best
- βοΈ Full Edit Capability: Edit every field of your trades including prices, dates, and P/L
- π MT5 Integration: Seamless import from MetaTrader 5 using our custom
TradeExporterscript - π― Smart Import: Assign account and strategy to all trades during import
- β Manual Trade Entry: Add trades manually with a user-friendly dialog for data not in MT5
- ποΈ Trade Management: Delete individual trades or clear all at once
- β»οΈ Rename & Update: Rename accounts or strategies and automatically update all associated trades
- π Multi-Account: Manage multiple trading accounts with starting balances
- π Trade Notes: Add comments and post-trade analysis to your records
- π Notes Tab: Dedicated space for writing and managing trading journal notes, ideas, and observations
- π Calendar Tab: Monthly calendar view with daily P&L, trade counts, color coding, and weekly P&L summary
- π¨ Professional UI: Custom application icon and modern interface
- π Cross-Platform: Works on Windows, macOS, and Linux
All Platforms:
- Java 11+ (JDK recommended for building)
- MetaTrader 5 (for exporting trading data)
- Windows: Download MT5
- macOS: Download MT5 for Mac
- Linux: Download MT5 for Linux
Windows:
- Windows 10/11
macOS:
- macOS 10.14+
- Install Java:
brew install openjdk@11 - Maven (optional):
brew install maven
Linux:
- Ubuntu/Debian or compatible distro
- Install Java:
sudo apt install openjdk-11-jdk - Maven (optional):
sudo apt install maven
- Download the latest release
- Unzip to a folder (e.g.,
C:\Journal) - Double-click
TradingJournal.exeto launch
- Clone or download this repository
- Make scripts executable:
chmod +x run.sh build.sh
- Build the application:
./build.sh
- Run the application:
Or directly:
./run.sh
java -jar target/trading-journal-1.0.0.jar
- Navigate to the
Trade Exporter/folder in this repository - Copy
TradeExporter.ex5 - Open MetaTrader 5, go to File β Open Data Folder
- Navigate to
MQL5\Scripts\(Windows) orMQL5/Scripts/(macOS/Linux) - Paste the file there
- In MT5 Navigator window (Ctrl+N / Cmd+N), right-click Scripts and select Refresh
- Drag
TradeExporterfrom Navigator onto any chart - Click OK
- A file named
TradingJournal_Export.txtwill be created inMQL5/Files- Windows:
%APPDATA%\MetaQuotes\Terminal\[instance]\MQL5\Files - macOS:
~/Library/Application Support/MetaTrader 5/Bottles/[instance]/drive_c/users/[user]/Application Data/MetaQuotes/Terminal/[instance]/MQL5/Files - Linux:
~/.wine/drive_c/Program Files/MetaTrader 5/MQL5/Files
- Windows:
- Open Trading Journal
- Click "Import TXT"
- Select the exported text file
- Choose an account for the imported trades
- Optionally choose a strategy to assign to all trades
- Your trades will appear instantly!
Main application window with trade list and analytics
Clear All Trades:
- Click File β Clear All Trades in the menu bar
Delete Individual Trades:
- Double-click any trade in the table
- Click the "Delete" button
- Confirm the deletion
Trade Details dialog - Edit everything, then Save or Delete
Edit All Trade Fields:
- Double-click any trade to open Trade Details
- Edit any field (prices, dates, P/L, commission, strategy, etc.)
- Click "Save" to apply changes
π‘ Tip: Net Profit is calculated automatically from Profit + Commission + Swap
Tools β Manage Strategies:
- Add Strategy: Create new strategy labels
- Rename Selected: Rename a strategy (automatically updates all trades)
- Remove Selected: Delete a strategy label
Tools β Manage Accounts:
- Add Account: Create account with starting balance
- Rename Selected: Rename an account (automatically updates all trades)
- Remove Selected: Delete an account
# Clone the repository
git clone https://github.com/janzofx/Trading_Journal.git
cd Trading_Journal
# Build
mvn clean package
# Run
java -jar target/trading-journal-1.0.0.jarWindows:
:: Build the application
build_app.bat
:: Run the application
TradingJournal.exemacOS/Linux:
./build.sh
./run.shThe main dashboard gives you an instant health check of your trading performance.
- Equity Curve: Visualizes the growth of your account over time. A healthy curve moves from bottom-left to top-right.
- Trade List: Detailed table of every trade. Double-click any row to edit prices, dates, or add notes.
- Quick Stats: Immediate view of your Win Rate, Net Profit, and Profit Factor at the top.
Drill down into your data to find exactly what is workingβand what isn't.
- Strategy: Filter by specific setups (e.g., "Trend Following" vs "Reversal").
- Symbol: See which instruments trigger the most wins.
- Account: Toggle between different trading accounts (e.g., "Live" vs "Prop Firm").
- Time: Filter by specific date ranges.
Switch to the Analytics tab for deep-dive statistics.
Performance Overview:
Detailed Breakdown (Hourly & Daily):
Monthly Progress:
- Win/Loss by Day: Identify your best trading days of the week.
- Hourly Performance: Find your most profitable times of day.
- Long vs Short: Analyze directional bias in your trading.
Importing trades is easier than ever. The import dialog now lets you bulk-assign properties.
- Account Assignment: Assign all imported trades to a specific account (e.g., "FTMO Challenge").
- Strategy Assignment: Tag an entire batch of trades with a strategy (e.g., "News Trading") instantly.
Forgot to log a trade? Add it manually.
- Complete Data: Enter entry/exit prices, times, and volume.
- Calculations: The system will automatically calculate P/L if you provide prices and size.
Capture your trading thoughts, strategies, and observations in a dedicated notes section.
- Organized Notes: Create and manage multiple notes with titles and timestamps
- Rich Editor: Write detailed trading journal entries, strategy ideas, or market observations
- Auto-Save: Changes are automatically saved when switching between notes
- Persistent Storage: All notes are saved locally and persist across sessions
Visualize your trading performance on a monthly calendar view.
- Monthly View: See your trading days at a glance with P&L displayed on each day
- Color Coding: Green for profitable days, red for losing days
- Trade Counts: Shows number of trades executed per day
- Weekly Summary: P&L per week displayed in the sidebar
- Navigation: Easily browse through months using Prev/Next buttons
Understanding your stats is key to improvement. Here is what every number tells you:
| Metric | Definition | Why it Matters |
|---|---|---|
| Net Profit | Total Profit - Total Loss |
The bottom line. Are you making money? |
| Profit Factor | Gross Profit / Gross Loss |
Measures the efficiency of your strategy. β’ < 1.0: Losing strategy β’ 1.0 - 1.5: Marginal / Break-even β’ 1.5 - 2.0: Good β’ > 2.0: Excellent |
| Win Rate | (Winning Trades / Total Trades) * 100 |
How often you are right. Note: High win rate doesn't guarantee profit if losses are large. |
| Expectancy | (Avg Win * Win Rate) - (Avg Loss * Loss Rate) |
The average amount you can expect to earn (or lose) per trade over the long run. Positive expectancy = profitable edge. |
| Sharpe Ratio | Risk-adjusted return metric. | Measures return per unit of risk. Higher is better (usually > 1.0). |
| Max Drawdown | Largest peak-to-valley percentage drop. | Measures the risk of your strategy. Lower is safer. |
| SQN (System Quality Number) | Statistical score of your trading system. | Used to evaluate the "quality" of your edge. β’ < 1.6: Poor β’ 1.6 - 2.0: Average β’ 2.0 - 2.5: Good β’ > 3.0: Excellent |
| Z-Score | Statistical measure of streaks. | Tells you if wins/losses are random or clustered. |
Trading Journal/
βββ src/main/java/ # Java Source Code
β βββ com/tradingjournal/
β βββ model/ # Data models (Trade, Account, Note, etc.)
β βββ repository/ # Data persistence layer
β βββ service/ # Business logic
β βββ ui/ # Swing UI components
βββ Trade Exporter/ # MT5 Export Script (.ex5 / .mq5)
βββ screenshots/ # Application screenshots
βββ target/ # Compiled binaries (generated)
βββ TradingJournal.exe # Windows launcher
βββ run.sh # macOS/Linux launcher
βββ build_app.bat # Windows build script
βββ build.sh # macOS/Linux build script
βββ icon.png # Application icon (PNG)
βββ icon.ico # Application icon (ICO)
βββ pom.xml # Maven configuration
βββ trades.json # Your trade database (auto-generated)
βββ accounts.json # Account data (auto-generated)
βββ strategies.json # Strategy labels (auto-generated)
βββ notes.json # Your notes database (auto-generated)
| Platform | Status | Notes |
|---|---|---|
| Windows 10/11 | β Full Support | Native .exe launcher with custom icon |
| macOS | β Full Support | Run via ./run.sh or JAR directly |
| Linux | β Full Support | Run via ./run.sh or JAR directly |
| MT5 Integration | β All Platforms | MT5 available natively on Windows, macOS, and Linux |
- β Calendar Tab - Monthly calendar view with daily P&L, color coding, and weekly summary
- β Notes Tab - Dedicated space for writing trading journal notes and observations
- β Full trade editing - Edit every field in Trade Details dialog
- β Strategy selection during import - Assign strategies when importing trades
- β Account renaming - Rename accounts and auto-update all trades
- β Strategy renaming - Rename strategies and auto-update all trades
- β macOS/Linux support - Cross-platform shell scripts
- β Enhanced UI - Professional custom icon and improved dialogs
- β Better screenshots - Complete visual guide in README
Contributions are welcome! Please feel free to submit a Pull Request.
- Fork the project
- Create your feature branch (
git checkout -b feature/AmazingFeature) - Commit your changes (
git commit -m 'Add some AmazingFeature') - Push to the branch (
git push origin feature/AmazingFeature) - Open a Pull Request
This project is open source and available for personal and educational use.
Happy Trading! ππ
Built with β€οΈ using Java, Swing, and JFreeChart










