Skip to content

Repository files navigation

Mizan Wealth Logo

Mizan Wealth

Balance your wealth. Know what’s due.

Next.js Tailwind CSS Google Gemini MetalPrice API

A browser-native, beautiful, and completely offline-capable Islamic finance dashboard built by a Muslim, for Muslims.


"And establish prayer and give Zakat, and whatever good you put forward for yourselves – you will find it with Allah." — (Surah Al-Baqarah 2:110)

Welcome to Mizan Wealth. Calculating Zakat, screening stocks for Shariah compliance, and managing your halal wealth shouldn't require complex spreadsheets or uploading your net worth to an external server.

Mizan Wealth is a unified, strictly local-first dashboard that adheres to authentic Islamic jurisprudence (Fiqh). It is designed to help you confidently calculate your Zakat obligations, purify your investments, and plan your financial future—all within a clean, utility-driven interface.

🌟 Why Choose Mizan Wealth?

  • 100% Privacy & Local-First: Your financial data is sensitive. The application uses your browser's localStorage to save your assets and liabilities locally. Your net worth never leaves your device. Portable JSON backups allow secure data transfer.
  • Exact Shariah Standards: Automatically calculates Nisab using precise South Asian Tola conversions: 87.48g for Gold and 612.36g for Silver.
  • Deep Fiqh Configurations: Easily configure the engine based on your school of thought (e.g., Hanafi vs. Shafi'i/Maliki/Hanbali for personal jewelry), set your preferred Nisab standard, and define stock investment intent (Long-term vs. Short-term).
  • Multi-Currency Scalability: Natively track your wealth in different fiat currencies (e.g., PKR, USD). Live spot rates seamlessly convert and scale to ensure your Nisab thresholds trigger with 100% accuracy in your local currency.
  • Hawl Automation: Input when you acquired an asset, and Mizan will calculate if a full lunar year (354 days) has passed.
  • Multi-Lingual: Full support for both English and Urdu (اردو), with stunning typography and a flawless Right-To-Left (RTL) layout.

🚀 Features

1. 📊 Advanced Zakat Engine

Enter your cash, business inventory, gold, silver, stocks, and deductible liabilities. The robust calculation engine processes negative liabilities intuitively and taps into live metal spot prices (with built-in TTL caching) to determine your exact Zakat obligation down to the penny.

2. 📈 Stock Purity Screener & Purification

Not all stocks are Halal to invest in. Our built-in screener checks companies against standard AAOIFI compliance criteria (Debt Ratio < 33%, Interest Income < 5%, Liquid Assets < 33%).

  • Accurate Purification: The app mathematically separates Capital Gains from Dividend Income. Capital gains on compliant stocks are 100% Halal, so purification is strictly calculated against non-compliant dividend revenue.

3. 🌱 Halal Growth Simulator

Project your financial future with a compound interest simulator that mathematically subtracts the annual 2.5% wealth tax (Zakat) and purification rates, giving you realistic Shariah-compliant growth models over time.

4. 📜 Mawarith (Inheritance) Modeler

A simple calculator to divide your estate according to explicit Quranic shares for spouses, parents, and children.

5. 🤖 AI Advisory Insights (Optional)

Connect your own Google Gemini API key to get personalized, actionable financial advice based purely on Islamic principles.


🛠️ Technology Stack

Mizan Wealth is built with the most modern web technologies to ensure lightning-fast performance and a premium user experience:

  • Framework: Next.js 14 (React App Router)
  • Styling: Tailwind CSS v3 with native CSS variable color mapping
  • Testing: Vitest for robust engine mathematical verification
  • AI Integration: Google Gemini Flash Models
  • Icons: Lucide React

⚙️ Getting Started (Run it Locally)

Want to run this yourself or contribute? It's easy!

Prerequisites

Make sure you have Node.js 18+ installed.

Installation

  1. Clone the repository:

    git clone https://github.com/rauf17/mizan-wealth.git
    cd mizan-wealth
  2. Install dependencies:

    npm install
  3. Set up Environment Variables:

    cp .env.example .env.local

    Optional: Open .env.local and add your METAL_PRICE_API_KEY for live gold/silver prices, and GEMINI_API_KEY for AI features. If you skip this, the app gracefully falls back to reliable mock data.

  4. Run the local server:

    npm run dev

    Open the local address displayed in your terminal.


🌐 Deployment Instructions

You can easily deploy your own instance of Mizan Wealth to Vercel:

  1. Import your GitHub repository into Vercel.
  2. Ensure the framework preset is set to Next.js.
  3. In the Vercel setup, paste your .env.local keys into the Environment Variables section.
  4. Click Deploy.

⚖️ Disclaimer

Mizan Wealth is a financial planning and calculation tool. The calculated outputs, stock purity results, and simulated projections are provided for educational and organizational purposes. They do not constitute formal religious rulings (Fatwa) or certified financial advice. We always advise cross-referencing complex Zakat cases with local certified Islamic scholars.


Built with Barakah. May Allah bless your wealth.

About

A browser-native Islamic finance dashboard for tracking wealth, purifying stock portfolios, and calculating Zakat with precise Shariah compliance.

Topics

Resources

Stars

2 stars

Watchers

0 watching

Forks

Releases

Packages

Contributors

Languages