Skip to content

preland/xmracer

Repository files navigation

XMRacer

A cost-effective mining hardware analysis tool that combines XMRig benchmarks with real-time pricing data to help you make informed decisions about cryptocurrency mining hardware purchases.

Features

  • XMRig Benchmark Integration: Automatically fetches the latest RandomX hashrate benchmarks
  • Multi-Source Pricing: Aggregates prices from Amazon, Newegg, B&H, Micro Center, and other retailers
  • Cost-Effectiveness Analysis: Calculates hash rate per dollar and hash rate per watt metrics
  • Total System Cost: Estimates the cost of supporting components (motherboard, RAM, cooling)
  • Interactive Charts: Visualize performance vs. price relationships
  • Smart Recommendations: Get buy/wait/avoid recommendations based on cost-efficiency scores

Tech Stack

  • Frontend: Next.js 14 with TypeScript and Tailwind CSS
  • Charts: Recharts for data visualization
  • Icons: Heroicons
  • Deployment: Optimized for Vercel

Getting Started

Prerequisites

  • Node.js 18+
  • npm or yarn

Installation

  1. Clone the repository:
git clone https://github.com/yourusername/xmracer.git
cd xmracer
  1. Install dependencies:
npm install
  1. Start the development server:
npm run dev
  1. Open http://localhost:3000 in your browser.

Data Sources

Benchmark Data

  • XMRig official benchmarks (https://xmrig.com/benchmark)
  • Community-submitted benchmark results
  • Verified testing results from hardware reviewers

Pricing Data

  • Amazon Product Advertising API
  • Newegg API
  • B&H Photo API
  • Micro Center pricing scraper
  • PCPartPicker integration (planned)

API Endpoints

GET /api/processors

Returns a list of processors with benchmark and pricing data.

{
  "id": "1",
  "name": "AMD Ryzen 9 7950X",
  "hashrate": 23000,
  "currentPrice": 549,
  "hashPerDollar": 41.9,
  "costEfficiencyScore": 92.5,
  "availabilityStatus": "in-stock"
}

GET /api/benchmarks

Returns raw benchmark data from XMRig sources.

GET /api/pricing/[processor]

Returns current pricing and price history for a specific processor.

Deployment on Vercel

  1. Push your code to GitHub
  2. Connect your repository to Vercel
  3. Deploy automatically on every push to main

The app is optimized for Vercel's serverless functions and edge runtime.

Environment Variables

Create a .env.local file with the following variables:

# API Keys (optional for enhanced functionality)
AMAZON_API_KEY=your_amazon_api_key
NEWEGG_API_KEY=your_newegg_api_key
BH_API_KEY=your_bh_api_key

# Rate limiting
RATE_LIMIT_PER_MINUTE=60

# Caching
CACHE_TTL_MINUTES=30

Roadmap

Phase 1 (Current)

  • Basic processor analysis
  • XMRig benchmark integration
  • Multi-source pricing
  • Cost-effectiveness metrics

Phase 2

  • GPU analysis for mining
  • Electricity cost calculator by region
  • Historical profitability analysis
  • Mining pool integration

Phase 3

  • Complete system builds
  • Reliability and warranty analysis
  • Used/refurbished market integration
  • Mobile app

Phase 4

  • Advanced ROI calculations
  • Market trend predictions
  • Custom build recommendations
  • Automated purchase alerts

Contributing

  1. Fork the repository
  2. Create a feature branch: git checkout -b feature/new-feature
  3. Commit your changes: git commit -am 'Add new feature'
  4. Push to the branch: git push origin feature/new-feature
  5. Submit a pull request

License

This project is licensed under the MIT License - see the LICENSE file for details.

Disclaimer

This tool is for informational purposes only. Cryptocurrency mining involves risks, and profitability can change rapidly due to market conditions, mining difficulty adjustments, and electricity costs. Always do your own research before making hardware purchases.

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published