How to Mine Monero (XMR) in 2026
Complete Guide
Everything you need to start mining Monero with your CPU. From hardware selection and wallet setup to XMRig configuration, pool connection, and performance optimization.
Monero (XMR) is a privacy-focused cryptocurrency that uses the RandomX algorithm, purpose-built for CPU mining. Here is the quick-start path:
- Hardware: Any modern CPU works — AMD Ryzen 7/9 or Intel i7/i9 with large L3 cache is ideal
- Software: XMRig (free, open-source) from github.com/xmrig/xmrig
- Pool: stratum+tcp://xmr.suprnova.cc:5222
- Wallet: Monero GUI Wallet or Feather Wallet for receiving payouts
- Key optimization: Enable huge pages for 20–30% hashrate boost
What Is Monero?
Monero (XMR) is a privacy-focused cryptocurrency launched in April 2014. Unlike Bitcoin, where all transactions are publicly visible on the blockchain, Monero uses advanced cryptographic techniques to make transactions untraceable and unlinkable by default.
Three core privacy technologies power Monero:
- Ring Signatures — Hide the sender by mixing your transaction with decoys from the blockchain
- Stealth Addresses — Generate one-time addresses for every transaction, hiding the receiver
- RingCT (Ring Confidential Transactions) — Conceal the transaction amount from everyone except sender and receiver
What makes Monero uniquely interesting for miners is its RandomX algorithm, adopted in November 2019. Our guide to mining algorithms covers how RandomX compares to other approaches. RandomX was specifically engineered to be CPU-friendly and ASIC-resistant, meaning you can mine Monero profitably with a regular desktop or server processor. No expensive GPUs or specialized mining hardware required.
Think of RandomX like a complex exam that requires reading from a large textbook (L3 cache). CPUs are like well-rounded students who can handle any question type. GPUs are like students who are great at math but struggle with reading comprehension — they have less cache per core, so they perform poorly on this particular exam.
Hardware Requirements
The single most important factor for Monero mining performance is your CPU's L3 cache size. RandomX requires 2 MB of L3 cache per mining thread. A processor with 32 MB of L3 cache can efficiently run 16 mining threads.
Why L3 Cache Matters
RandomX works by executing randomly generated programs that heavily access a 2 MB memory scratchpad. If this scratchpad fits in L3 cache, the CPU can access it hundreds of times faster than if it had to reach out to main RAM. More L3 cache means more threads running at full speed.
Optimal thread count = L3 cache (MB) / 2. A Ryzen 9 7950X with 64 MB L3 cache can run 32 threads. A Core i7-13700K with 30 MB L3 cache should run 15 threads. Going above this causes cache thrashing and reduces per-thread performance.
Recommended CPUs for Monero Mining
| CPU | Cores/Threads | L3 Cache | Expected Hashrate | Rating |
|---|---|---|---|---|
| AMD Threadripper PRO 5995WX | 64C/128T | 256 MB | ~45–55 KH/s | Excellent |
| AMD EPYC 7763 | 64C/128T | 256 MB | ~44–52 KH/s | Excellent |
| AMD Ryzen 9 7950X | 16C/32T | 64 MB | ~20–22 KH/s | Great |
| AMD Ryzen 9 5950X | 16C/32T | 64 MB | ~17–19 KH/s | Great |
| AMD Ryzen 7 7700X | 8C/16T | 32 MB | ~10–12 KH/s | Good |
| AMD Ryzen 7 5800X | 8C/16T | 32 MB | ~9–11 KH/s | Good |
| Intel Core i9-13900K | 24C/32T | 36 MB | ~11–14 KH/s | Good |
| Intel Core i7-13700K | 16C/24T | 30 MB | ~9–11 KH/s | Good |
| AMD Ryzen 5 5600X | 6C/12T | 32 MB | ~7–8 KH/s | Decent |
| Intel Core i5-12400 | 6C/12T | 18 MB | ~5–6 KH/s | Entry-level |
AMD processors consistently outperform Intel at the same price point for Monero mining due to their larger L3 caches. The Ryzen 9 7950X with its 64 MB of L3 cache offers the best performance-per-dollar for most miners.
Other Hardware Considerations
- RAM: 8 GB minimum, 16 GB recommended. RAM speed has minimal impact on RandomX hashrate.
- Storage: Any SSD or HDD is fine — mining is CPU-bound, not storage-bound.
- Power Supply: Size appropriately for your CPU's TDP. A Ryzen 9 7950X draws ~170W under mining load.
- Cooling: Sustained CPU workload generates constant heat. A good tower cooler or AIO liquid cooler is essential. Thermal throttling directly reduces hashrate.
- Motherboard: No special requirements. Any board that supports your CPU works.
Step 1: Set Up a Monero Wallet
Before you start mining, you need a Monero wallet address to receive payouts. There are two recommended options:
The official desktop wallet from the Monero project. Download from getmonero.org. Available for Windows, macOS, and Linux. Full-featured with built-in node support.
- Download from the official site and verify the GPG signature
- Choose "Simple mode" for light wallet (connects to remote node) or "Advanced mode" to run your own node
- Write down and securely store your 25-word mnemonic seed — this is your backup
- Your wallet address starts with
4(95 characters) or8(subaddress)
A lightweight, privacy-focused desktop wallet. Download from featherwallet.org. Faster setup than the GUI wallet, connects to remote nodes by default, and supports Tor out of the box.
- No blockchain sync required — connects to remote nodes automatically
- Built-in Tor support for enhanced privacy
- Coin control and advanced transaction features
- Available for Windows, macOS, Linux, and Tails OS
Never use a wallet address from a third-party website or unknown source. Always download wallet software from official sites and verify signatures. Your mnemonic seed gives complete access to your funds — store it offline, never share it, and never enter it on any website.
Step 2: Download and Install XMRig
XMRig is the most popular and best-performing miner for Monero's RandomX algorithm. It is free, open-source, and actively maintained.
Download XMRig
Get the latest release from the official GitHub repository:
# Official XMRig repository
https://github.com/xmrig/xmrig/releases
# Download the latest release for your platform:
# Windows: xmrig-x.x.x-msvc-win64.zip
# Linux: xmrig-x.x.x-linux-static-x64.tar.gz
Fake XMRig downloads with embedded malware are extremely common. Only download from github.com/xmrig/xmrig. Check the SHA-256 hash of your download against the hash listed on the GitHub release page. Never download XMRig from random websites, forums, or file-sharing services.
Windows Installation
- Download the latest
xmrig-*-msvc-win64.zipfrom GitHub Releases - Extract the ZIP to a folder (e.g.,
C:\xmrig\) - You may need to add an exclusion in Windows Defender — AV software often flags miners as "PUP" (Potentially Unwanted Program) even when they are legitimate
- Open the folder — you should see
xmrig.exeandconfig.json
Linux Installation
# Download and extract
wget https://github.com/xmrig/xmrig/releases/download/v6.x.x/xmrig-6.x.x-linux-static-x64.tar.gz
tar -xzf xmrig-*.tar.gz
cd xmrig-*
# Make executable
chmod +x xmrig
# Test that it runs
./xmrig --version
Step 3: Configure Pool Mining on xmr.suprnova.cc
Now connect XMRig to Suprnova's Monero pool. First, create an account at xmr.suprnova.cc and set up a worker in your account dashboard.
- Stratum URL: stratum+tcp://xmr.suprnova.cc:5222
- Worker format: USERNAME.WORKERNAME
- Password: x
- Algorithm: RandomX (rx/0)
Windows: Create a BAT File
Create a file called mine.bat in the same folder as xmrig.exe:
xmrig.exe -o stratum+tcp://xmr.suprnova.cc:5222 -u USERNAME.WORKERNAME -p x
Replace USERNAME with your Suprnova username and WORKERNAME with your worker name (e.g., myrig).
Windows: Using config.json
Alternatively, edit the config.json file for more control:
{
"autosave": true,
"cpu": true,
"opencl": false,
"cuda": false,
"pools": [
{
"url": "stratum+tcp://xmr.suprnova.cc:5222",
"user": "USERNAME.WORKERNAME",
"pass": "x",
"keepalive": true,
"tls": false
}
]
}
Linux: Command Line
# Basic start command
./xmrig -o stratum+tcp://xmr.suprnova.cc:5222 -u USERNAME.WORKERNAME -p x
# Run in background with log file
nohup ./xmrig -o stratum+tcp://xmr.suprnova.cc:5222 -u USERNAME.WORKERNAME -p x > xmrig.log 2>&1 &
# Run with systemd (recommended for servers)
# Create /etc/systemd/system/xmrig.service
Linux: systemd Service (Recommended for Servers)
# /etc/systemd/system/xmrig.service
[Unit]
Description=XMRig Monero Miner
After=network.target
[Service]
Type=simple
ExecStart=/opt/xmrig/xmrig --config /opt/xmrig/config.json
Restart=always
RestartSec=10
Nice=10
[Install]
WantedBy=multi-user.target
# Enable and start the service
sudo systemctl enable xmrig
sudo systemctl start xmrig
sudo systemctl status xmrig
# View logs
sudo journalctl -u xmrig -f
Step 4: Enable Huge Pages (Critical Optimization)
Enabling huge pages is the single most impactful optimization for XMRig. It typically improves hashrate by 20–30% with zero additional hardware cost.
Why Huge Pages Matter
Normal memory pages are 4 KB. RandomX's scratchpad is 2 MB per thread. Without huge pages, the CPU must manage 512 small page table entries per scratchpad. With 2 MB huge pages, it only needs 1 entry. This massively reduces TLB (Translation Lookaside Buffer) misses and speeds up memory access.
Windows: Enable Huge Pages
- Run XMRig as Administrator — Right-click
xmrig.exeor your BAT file and select "Run as administrator" - XMRig will automatically try to enable huge pages on Windows when run with admin privileges
- If automatic setup fails, manually enable via Local Security Policy:
secpol.msc→ Local Policies → User Rights Assignment → Lock pages in memory → Add your user - Reboot after changing the policy
Linux: Enable Huge Pages
# Check current huge pages
cat /proc/meminfo | grep HugePages
# Enable huge pages (calculate: threads * 2 MB + 64 MB buffer)
# For 16 mining threads: (16 * 2) + 64 = 96 MB = 48 huge pages
sudo sysctl -w vm.nr_hugepages=1168
# Make permanent (survives reboot)
echo "vm.nr_hugepages=1168" | sudo tee -a /etc/sysctl.conf
sudo sysctl -p
# XMRig also supports 1 GB huge pages for even better performance
# Requires GRUB parameter: hugepagesz=1G hugepages=3
When XMRig starts, check the output for HUGE PAGES: 100%. If you see HUGE PAGES: 0% or a partial percentage, huge pages are not fully configured. The hashrate difference is very noticeable — do not skip this step.
Step 5: Optimize XMRig Performance
Beyond huge pages, several additional tweaks can squeeze more hashrate from your hardware:
Thread Count and CPU Affinity
XMRig auto-detects the optimal thread count, but you may want to manually adjust it:
# Specify thread count explicitly
./xmrig -o stratum+tcp://xmr.suprnova.cc:5222 -u USER.WORKER -p x -t 16
# Leave 1-2 threads free for the OS (recommended for desktop use)
# Example: 16-core CPU, use 14 threads
./xmrig -o stratum+tcp://xmr.suprnova.cc:5222 -u USER.WORKER -p x -t 14
For dedicated mining machines, use all available threads. For a desktop you also use for other tasks, leave 1–2 threads free to keep the system responsive.
Memory and NUMA Optimization
- Dual-channel RAM: Use two sticks of RAM for dual-channel bandwidth. Single-channel configurations can lose 5–10% hashrate.
- NUMA awareness: On multi-socket servers (EPYC, Threadripper PRO), XMRig automatically detects NUMA topology. Ensure
"numa": truein config.json. - RAM speed: Minor impact on RandomX. DDR4-3200 vs DDR4-3600 makes less than 2% difference. Do not overspend on fast RAM for mining.
Power Optimization
- Undervolting: Reducing CPU voltage by 50–100mV can save 20–40W while maintaining full hashrate. Use Ryzen Master (AMD) or Intel XTU (Intel). A profitability calculator can help you weigh power savings against earnings.
- Eco Mode (AMD): Ryzen Eco Mode reduces TDP by ~30% with only 5–10% hashrate loss. Excellent for efficiency.
- Disable SMT/HT: In some cases, disabling hyper-threading and using only physical cores can improve per-core hashrate if cache is limited.
Advanced config.json Tuning
{
"cpu": {
"enabled": true,
"huge-pages": true,
"huge-pages-jit": true,
"hw-aes": null,
"priority": null,
"memory-pool": false,
"yield": true,
"max-threads-hint": 100,
"asm": true,
"argon2-impl": null,
"rx": {
"init": -1,
"init-avx2": -1,
"mode": "auto",
"1gb-pages": false,
"rdmsr": true,
"wrmsr": true,
"cache_qos": false,
"numa": true
}
}
}
Expected Hashrates by CPU
Here are real-world RandomX hashrates you can expect from popular processors. These assume huge pages enabled and optimal thread counts:
| CPU | Hashrate (H/s) | Threads | Power (W) | Efficiency (H/W) |
|---|---|---|---|---|
| AMD Threadripper PRO 5995WX | ~50,000 | 128 | ~280 | ~178 |
| AMD EPYC 7763 | ~48,000 | 128 | ~280 | ~171 |
| AMD Ryzen 9 7950X | ~21,000 | 32 | ~170 | ~124 |
| AMD Ryzen 9 5950X | ~18,000 | 32 | ~140 | ~129 |
| AMD Ryzen 9 5900X | ~15,000 | 24 | ~120 | ~125 |
| AMD Ryzen 7 7700X | ~11,000 | 16 | ~105 | ~105 |
| AMD Ryzen 7 5800X | ~10,000 | 16 | ~95 | ~105 |
| Intel Core i9-13900K | ~13,000 | 18 | ~180 | ~72 |
| Intel Core i7-13700K | ~10,500 | 15 | ~150 | ~70 |
| AMD Ryzen 5 5600X | ~7,800 | 12 | ~70 | ~111 |
| Intel Core i5-12400 | ~5,500 | 9 | ~80 | ~69 |
| Apple M2 Pro (10-core) | ~5,000 | 8 | ~30 | ~167 |
AMD Ryzen processors dominate the efficiency column thanks to their large L3 caches. Note that Intel's E-cores (efficiency cores) perform poorly on RandomX — XMRig should only use P-cores (performance cores) on hybrid Intel processors.
Linux Mining Setup
Linux is the preferred operating system for Monero mining, especially on dedicated mining machines and servers. It has lower overhead than Windows and better huge page support.
Quick Setup on Ubuntu/Debian
# 1. Update system
sudo apt update && sudo apt upgrade -y
# 2. Download XMRig
cd /opt
sudo wget https://github.com/xmrig/xmrig/releases/download/v6.x.x/xmrig-6.x.x-linux-static-x64.tar.gz
sudo tar -xzf xmrig-*.tar.gz
sudo mv xmrig-*/ xmrig
cd xmrig
# 3. Configure huge pages
sudo sysctl -w vm.nr_hugepages=1168
echo "vm.nr_hugepages=1168" | sudo tee -a /etc/sysctl.conf
# 4. Edit config.json with your pool details
sudo nano config.json
# 5. Run XMRig
sudo ./xmrig
# 6. Verify output shows:
# HUGE PAGES: 100%
# [pool] connected to xmr.suprnova.cc:5222
MSR Mod (Linux Only)
XMRig can apply MSR (Model Specific Register) tweaks that improve RandomX performance by 5–15% on Intel CPUs. This requires root privileges and the msr kernel module:
# Load MSR module
sudo modprobe msr
# XMRig will automatically apply MSR tweaks when run as root
# Look for "msr register values have been set successfully" in output
sudo ./xmrig --config config.json
MSR modifications reset on reboot. They are safe and do not permanently change your CPU. The biggest gain is on Intel processors (up to 15%). AMD Ryzen processors see smaller gains (2–5%) since they already have large L3 caches. Always run XMRig with sudo or as root for MSR access.
Security Best Practices
Mining software is a frequent target for malware. Cryptojacking (unauthorized mining) is one of the most common forms of malware. Read our full mining pool security guide for comprehensive protection. Here is how to protect yourself:
- Only download XMRig from GitHub: github.com/xmrig/xmrig/releases — not from third-party sites, YouTube descriptions, or forum links
- Verify the checksum: Compare the SHA-256 hash of your download against the one listed on the GitHub release page
- Check your config.json: Ensure the pool address and wallet belong to you. Trojaned miners often hardcode the attacker's wallet
- Monitor your hashrate: If your hashrate on the pool dashboard is lower than XMRig reports, something may be redirecting a portion of your hashpower
- Use a dedicated machine or VM: Do not mine on a machine that holds cryptocurrency wallets with significant funds
Verifying XMRig Downloads
# On Linux/macOS:
sha256sum xmrig-*.tar.gz
# On Windows (PowerShell):
Get-FileHash xmrig-*.zip -Algorithm SHA256
# Compare the output hash with the one on:
# https://github.com/xmrig/xmrig/releases
# If they don't match, DO NOT use the file
Antivirus False Positives
Legitimate mining software is frequently flagged as a "PUP" (Potentially Unwanted Program) or "Trojan:Win32/CoinMiner" by antivirus software. This is because the same mining code is used in both legitimate miners and cryptojacking malware. If you downloaded XMRig from the official GitHub and verified the hash, these are false positives. Add the XMRig folder to your antivirus exclusion list.
Troubleshooting Common Issues
On Windows, run as Administrator. On Linux, set vm.nr_hugepages via sysctl and run as root. This is the #1 performance issue.
Verify the pool address is exactly stratum+tcp://xmr.suprnova.cc:5222. Check your firewall allows outbound connections on port 5222. Try using a different DNS server if resolution fails.
Check: (1) huge pages status, (2) thermal throttling (CPU temp above 90C), (3) background processes competing for CPU, (4) single-channel RAM, (5) incorrect thread count. On Intel hybrid CPUs, ensure XMRig uses only P-cores.
A small number of rejected shares (<1%) is normal. High rejection rates suggest network latency to the pool, unstable overclocks, or hardware issues. Check your CPU stability with a stress test.
Getting Started Checklist
1. Wallet: Download Monero GUI Wallet or Feather Wallet. Write down your seed phrase and keep it safe. Copy your wallet address.
2. Pool account: Register at xmr.suprnova.cc. Create a worker in your account settings. Set your wallet address for payouts.
3. XMRig: Download from github.com/xmrig/xmrig. Verify the SHA-256 hash. Configure with your pool credentials.
4. Huge pages: Enable huge pages before starting. This single step boosts hashrate by 20–30%.
5. Start mining: Launch XMRig and verify it connects to the pool. Check your worker appears on the pool dashboard. Monitor temperatures and hashrate.
6. Optimize: Fine-tune thread count, consider undervolting, and apply MSR tweaks on Linux for the best efficiency.