# MFapi.in

> Track Indian mutual funds with MFapi.in, a free API for the daily NAV of every scheme registered with AMFI, with full history. Find a fund by name, fund house or type, get its latest NAV or NAV history, see its returns over 1 week to 10 years, and work out what a one-time investment or a monthly SIP would be worth today.

App · 6 actions. Web page: https://docs.lodol.com/docs/integrations/mfapi

## Actions

### Calculate investment returns

Work out what a one-time investment in a fund returned between two dates: the buying and selling NAVs, the return in percent and per year, and, if you give an amount, the units bought and what they are worth now. Ignores exit loads and taxes.

**Inputs**

- Fund (`fund`, text, required): The fund to look up. The list has the Direct Growth plan of every open fund. For any other plan, type its scheme code (a number such as 122639, which Search funds returns), its ISIN from your statement, or its full name.
- Invested on (`start_date`, date, required): The day the money went in. If the market was closed that day, the next day's NAV is used, as it would be for a real order.
- Value on (`end_date`, date): The day to value the investment. Leave empty for the latest NAV. If the market was closed that day, the last NAV before it is used.
- Amount invested (₹) (`amount`, number): Rupees invested. Leave empty to get just the return in percent. From 1.0 to 1000000000.0.

**Outputs**

- `absolute_return_percent` (number): Total return, %.
- `amount_invested` (number): Rupees in.
- `annualized_return_percent` (number): Return per year (CAGR), %. Empty for less than a year.
- `current_value` (number): What the units are worth, in rupees.
- `days_held` (number): Days between them.
- `end_nav` (number): Selling NAV.
- `end_nav_date` (text): Date of the selling NAV.
- `fund_house` (text): The fund house (AMC).
- `gain` (number): Profit in rupees.
- `scheme_code` (number): AMFI scheme code.
- `scheme_name` (text): Full scheme name.
- `start_nav` (number): Buying NAV.
- `start_nav_date` (text): Date of the buying NAV.
- `units` (number): Units bought.

**Example output**

```json
{
  "absolute_return_percent": 221.42,
  "amount_invested": 10000.0,
  "annualized_return_percent": 18.77,
  "current_value": 32141.73,
  "days_held": 2478,
  "end_nav": 89.3598,
  "end_nav_date": "2026-10-14",
  "fund_house": "PPFAS Mutual Fund",
  "gain": 22141.73,
  "scheme_code": 122639,
  "scheme_name": "Parag Parikh Flexi Cap Fund - Direct Plan - Growth",
  "start_nav": 27.8018,
  "start_nav_date": "2020-01-01",
  "units": 359.6889
}
```

### Calculate SIP returns

Work out what a monthly SIP (a fixed amount invested every month) in a fund would be worth: each instalment, the total invested, units held, current value, gain and XIRR (the per-year return that allows for when each instalment went in). Instalments fall on the start date's day of each month. Ignores exit loads, stamp duty and taxes.

**Inputs**

- Fund (`fund`, text, required): The fund to look up. The list has the Direct Growth plan of every open fund. For any other plan, type its scheme code (a number such as 122639, which Search funds returns), its ISIN from your statement, or its full name.
- Monthly amount (₹) (`monthly_amount`, number, required): Rupees invested each month. From 1.0 to 1000000000.0.
- First instalment (`start_date`, date, required): The date of the first instalment. Later ones fall on the same day of each month; on a holiday the next day's NAV is used.
- Value on (`end_date`, date): The day to value the investment. Leave empty for the latest NAV. If the market was closed that day, the last NAV before it is used.

**Outputs**

- `absolute_return_percent` (number): Gain as a share of the total invested, %.
- `current_value` (number): What the units are worth, in rupees.
- `end_nav` (number): NAV used to value them.
- `end_nav_date` (text): Its date.
- `first_installment_date` (text): NAV date of the first instalment.
- `fund_house` (text): The fund house (AMC).
- `gain` (number): Profit in rupees.
- `installment_count` (number): Instalments made.
- `installments` (list)
- `last_installment_date` (text): NAV date of the last instalment.
- `monthly_amount` (number): Rupees a month.
- `scheme_code` (number): AMFI scheme code.
- `scheme_name` (text): Full scheme name.
- `total_invested` (number): Rupees in.
- `total_units` (number): Units held.
- `xirr_percent` (number): Per-year return allowing for timing (XIRR), %.

**Example output**

```json
{
  "absolute_return_percent": 132.46,
  "current_value": 23245.69,
  "end_nav": 89.3598,
  "end_nav_date": "2026-10-14",
  "first_installment_date": "2021-01-05",
  "fund_house": "PPFAS Mutual Fund",
  "gain": 13245.69,
  "installment_count": 2,
  "installments": [
    {
      "amount": 5000.0,
      "due_date": "2021-01-05",
      "nav": 37.2856,
      "nav_date": "2021-01-05",
      "units": 134.1
    },
    {
      "amount": 5000.0,
      "due_date": "2021-02-05",
      "nav": 39.6704,
      "nav_date": "2021-02-05",
      "units": 126.0386
    }
  ],
  "last_installment_date": "2021-02-05",
  "monthly_amount": 5000.0,
  "scheme_code": 122639,
  "scheme_name": "Parag Parikh Flexi Cap Fund - Direct Plan - Growth",
  "total_invested": 10000.0,
  "total_units": 260.1386,
  "xirr_percent": 16.12
}
```

### Get fund performance

Get a fund's returns over the last week, month, 3 and 6 months and year, per-year returns (CAGR) over 3, 5 and 10 years, its return since its first NAV, and its 52-week high and low. A period longer than the fund has existed is left empty.

**Inputs**

- Fund (`fund`, text, required): The fund to look up. The list has the Direct Growth plan of every open fund. For any other plan, type its scheme code (a number such as 122639, which Search funds returns), its ISIN from your statement, or its full name.

**Outputs**

- `annualized_return_since_first_nav` (number): Per-year return since the first NAV (CAGR), %.
- `first_nav` (number): That first NAV.
- `first_nav_date` (text): The fund's first NAV date on MFapi.in.
- `fund_house` (text): The fund house (AMC).
- `high_52_week` (number): 52-week high NAV.
- `high_52_week_date` (text): Its date.
- `isin_div_reinvestment` (text): ISIN of the dividend reinvestment units.
- `isin_growth` (text): ISIN of the growth units.
- `low_52_week` (number): 52-week low NAV.
- `low_52_week_date` (text): Its date.
- `nav` (number): Latest NAV in rupees.
- `nav_date` (text): Date of that NAV.
- `option` (text): Growth or IDCW (dividend), empty if unknown.
- `plan` (text): Direct or Regular (empty if unknown).
- `return_10_year` (number): Return per year over 10 years (CAGR), %.
- `return_1_month` (number): Return over 1 month, %.
- `return_1_week` (number): Return over 1 week, %.
- `return_1_year` (number): Return over 1 year, %.
- `return_3_month` (number): Return over 3 months, %.
- `return_3_year` (number): Return per year over 3 years (CAGR), %.
- `return_5_year` (number): Return per year over 5 years (CAGR), %.
- `return_6_month` (number): Return over 6 months, %.
- `return_since_first_nav` (number): Return since the first NAV, %.
- `scheme_category` (text): Category as filed with AMFI, e.g. Equity Scheme - Small Cap Fund.
- `scheme_code` (number): AMFI scheme code.
- `scheme_name` (text): Full scheme name.
- `scheme_type` (text): Open ended, close ended or interval scheme.

**Example output**

```json
{
  "annualized_return_since_first_nav": 17.77,
  "first_nav": 9.9992,
  "first_nav_date": "2013-05-28",
  "fund_house": "PPFAS Mutual Fund",
  "high_52_week": 95.7732,
  "high_52_week_date": "2025-10-27",
  "isin_div_reinvestment": null,
  "isin_growth": "INF879O01027",
  "low_52_week": 85.2599,
  "low_52_week_date": "2026-03-30",
  "nav": 89.3598,
  "nav_date": "2026-10-14",
  "option": "Growth",
  "plan": "Direct",
  "return_10_year": 16.63,
  "return_1_month": -0.24,
  "return_1_week": 0.59,
  "return_1_year": -4.12,
  "return_3_month": -1.94,
  "return_3_year": 12.02,
  "return_5_year": 10.3,
  "return_6_month": -2.42,
  "return_since_first_nav": 793.67,
  "scheme_category": "Equity Scheme - Flexi Cap Fund",
  "scheme_code": 122639,
  "scheme_name": "Parag Parikh Flexi Cap Fund - Direct Plan - Growth",
  "scheme_type": "Open Ended Schemes"
}
```

### Get latest NAV

Get a fund's most recent NAV (the price of one unit) and the date it was published, with the fund's details. Fund houses publish NAVs each business day evening.

**Inputs**

- Fund (`fund`, text, required): The fund to look up. The list has the Direct Growth plan of every open fund. For any other plan, type its scheme code (a number such as 122639, which Search funds returns), its ISIN from your statement, or its full name.

**Outputs**

- `fund_house` (text): The fund house (AMC).
- `isin_div_reinvestment` (text): ISIN of the dividend reinvestment units.
- `isin_growth` (text): ISIN of the growth units.
- `nav` (number): Latest NAV in rupees.
- `nav_date` (text): Date of that NAV (YYYY-MM-DD).
- `option` (text): Growth or IDCW (dividend), empty if unknown.
- `plan` (text): Direct or Regular (empty if unknown).
- `scheme_category` (text): Category as filed with AMFI, e.g. Equity Scheme - Small Cap Fund.
- `scheme_code` (number): AMFI scheme code.
- `scheme_name` (text): Full scheme name.
- `scheme_type` (text): Open ended, close ended or interval scheme.

**Example output**

```json
{
  "fund_house": "PPFAS Mutual Fund",
  "isin_div_reinvestment": null,
  "isin_growth": "INF879O01027",
  "nav": 89.3598,
  "nav_date": "2026-10-14",
  "option": "Growth",
  "plan": "Direct",
  "scheme_category": "Equity Scheme - Flexi Cap Fund",
  "scheme_code": 122639,
  "scheme_name": "Parag Parikh Flexi Cap Fund - Direct Plan - Growth",
  "scheme_type": "Open Ended Schemes"
}
```

### Get NAV history

Get every NAV a fund published between two dates, oldest first, with the change over the period and its highest and lowest NAV. Leave both dates empty for the last 30 days. Weekends and market holidays have no NAV.

**Inputs**

- Fund (`fund`, text, required): The fund to look up. The list has the Direct Growth plan of every open fund. For any other plan, type its scheme code (a number such as 122639, which Search funds returns), its ISIN from your statement, or its full name.
- From (`start_date`, date): The first day to include. Defaults to 30 days before To.
- To (`end_date`, date): The last day to include. Defaults to today.

**Outputs**

- `change` (number): Last NAV minus first NAV, in rupees.
- `change_percent` (number): Change over the period, %.
- `end_date` (text): Range end.
- `first_nav` (number): First NAV.
- `first_nav_date` (text): Its date.
- `fund_house` (text): The fund house (AMC).
- `highest_nav` (number): Highest NAV.
- `highest_nav_date` (text): Its date.
- `last_nav` (number): Last NAV.
- `last_nav_date` (text): Its date.
- `lowest_nav` (number): Lowest NAV.
- `lowest_nav_date` (text): Its date.
- `nav_count` (number): NAVs returned.
- `navs` (list)
- `scheme_code` (number): AMFI scheme code.
- `scheme_name` (text): Full scheme name.
- `start_date` (text): Range start.

**Example output**

```json
{
  "change": -0.2359,
  "change_percent": -0.33,
  "end_date": "2024-01-03",
  "first_nav": 70.4621,
  "first_nav_date": "2024-01-01",
  "fund_house": "PPFAS Mutual Fund",
  "highest_nav": 70.4621,
  "highest_nav_date": "2024-01-01",
  "last_nav": 70.2262,
  "last_nav_date": "2024-01-03",
  "lowest_nav": 70.2262,
  "lowest_nav_date": "2024-01-03",
  "nav_count": 3,
  "navs": [
    {
      "date": "2024-01-01",
      "nav": 70.4621
    },
    {
      "date": "2024-01-02",
      "nav": 70.3278
    },
    {
      "date": "2024-01-03",
      "nav": 70.2262
    }
  ],
  "scheme_code": 122639,
  "scheme_name": "Parag Parikh Flexi Cap Fund - Direct Plan - Growth",
  "start_date": "2024-01-01"
}
```

### Search funds

Find Indian mutual funds by name, fund house or type, with each one's scheme code and latest NAV. Every word you type must appear in the name, in any order. Open funds come first, and only Direct Growth plans are shown unless you change Plan or Option.

**Inputs**

- Search for (`query`, text): Words from the fund's name. Leave empty to list a fund house's or a type's funds.
- Fund house (`fund_house`, text): Only funds from this fund house (AMC).
- Fund type (`asset_class`, text): Only funds of this type. One of: `any`, `equity`, `debt`, `hybrid`, `index` (Index fund or ETF), `fund_of_funds` (Fund of funds), `solution` (Retirement or children's), `other`. Default: `any`.
- Plan (`plan`, text): Direct plans are bought straight from the fund house and cost less; Regular plans are sold through a distributor. One of: `direct`, `regular`, `any`. Default: `direct`.
- Option (`option`, text): Growth reinvests profits; IDCW pays them out as dividends. One of: `growth`, `idcw` (IDCW (dividend)), `any`. Default: `growth`.
- Include closed funds (`include_closed`, true/false): Also list funds that no longer publish a NAV, such as matured or merged schemes. Default: `false`.
- Number of results (`limit`, number): How many funds to return, up to 200. Defaults to 20. From 1 to 200. Default: `20`.

**Outputs**

- `fund_count` (number): How many funds are returned.
- `funds` (list)
- `query` (text): What was searched.
- `total_matches` (number): How many funds matched in all.

**Example output**

```json
{
  "fund_count": 1,
  "funds": [
    {
      "asset_class": "Equity",
      "fund_house": "PPFAS Mutual Fund",
      "is_open": true,
      "isin_div_reinvestment": null,
      "isin_growth": "INF879O01027",
      "nav": 89.3598,
      "nav_date": "2026-10-14",
      "option": "Growth",
      "plan": "Direct",
      "scheme_category": "Equity Scheme - Flexi Cap Fund",
      "scheme_code": 122639,
      "scheme_name": "Parag Parikh Flexi Cap Fund - Direct Plan - Growth",
      "scheme_type": "Open Ended Schemes"
    }
  ],
  "query": "parag parikh flexi",
  "total_matches": 1
}
```
