v3.25.4

Investments - Schedule of Contractual Maturities of Securities Available for Sale (Details) - USD ($) $ in Thousands | Dec. 31, 2025 | Jun. 30, 2025
--- | --- | ---
Debt Securities, Available-for-sale [Line Items] |  |
Within 1 year, amortized cost | $ 498,340 | $ 673,109
Within 1 year, fair value | 499,150 | 673,543
Greater than 1 year, less than or equal to 5 years, amortized cost | 223,396 | 219,059
Greater than 1 year, less than or equal to 5 years, fair value | 224,225 | 218,934
Amortized Cost | 721,736 | 892,168
Fair Value | 723,375 | 892,477
Certificates of deposit |  |
Debt Securities, Available-for-sale [Line Items] |  |
Within 1 year, amortized cost | 36,500 | 38,990
Within 1 year, fair value | 36,552 | 39,008
Greater than 1 year, less than or equal to 5 years, amortized cost | 0 | 0
Greater than 1 year, less than or equal to 5 years, fair value | 0 | 0
Amortized Cost | 36,500 | 38,990
Fair Value | 36,552 | 39,008
Corporate bonds |  |
Debt Securities, Available-for-sale [Line Items] |  |
Within 1 year, amortized cost | 153,866 | 149,435
Within 1 year, fair value | 154,144 | 149,675
Greater than 1 year, less than or equal to 5 years, amortized cost | 87,490 | 114,060
Greater than 1 year, less than or equal to 5 years, fair value | 88,033 | 114,524
Amortized Cost | 241,356 | 263,495
Fair Value | 242,177 | 264,199
Commercial paper |  |
Debt Securities, Available-for-sale [Line Items] |  |
Within 1 year, amortized cost | 63,869 |
Within 1 year, fair value | 63,943 |
Greater than 1 year, less than or equal to 5 years, amortized cost | 0 |
Greater than 1 year, less than or equal to 5 years, fair value | 0 |
Amortized Cost | 63,869 |
Fair Value | 63,943 | 126,761
Within 1 year, including cash, amortized cost |  | 139,336
Within 1 year, including cash, fair value |  | 139,325
Greater than 1 year, less than or equal to 5 years, including cash, amortized cost |  | 0
Greater than 1 year, less than or equal to 5 years, including cash, fair value |  | 0
Including cash, amortized cost |  | 139,336
Including cash, fair value |  | 139,325
Agency bonds |  |
Debt Securities, Available-for-sale [Line Items] |  |
Within 1 year, amortized cost | 5,049 |
Within 1 year, fair value | 5,051 |
Greater than 1 year, less than or equal to 5 years, amortized cost | 0 |
Greater than 1 year, less than or equal to 5 years, fair value | 0 |
Amortized Cost | 5,049 |
Fair Value | 5,051 | 7,854
Within 1 year, including cash, amortized cost |  | 11,358
Within 1 year, including cash, fair value |  | 11,347
Greater than 1 year, less than or equal to 5 years, including cash, amortized cost |  | 0
Greater than 1 year, less than or equal to 5 years, including cash, fair value |  | 0
Including cash, amortized cost |  | 11,358
Including cash, fair value |  | 11,347
Municipal bonds |  |
Debt Securities, Available-for-sale [Line Items] |  |
Within 1 year, amortized cost | 4,511 | 3,944
Within 1 year, fair value | 4,519 | 3,950
Greater than 1 year, less than or equal to 5 years, amortized cost | 3,899 | 2,113
Greater than 1 year, less than or equal to 5 years, fair value | 3,916 | 2,126
Amortized Cost | 8,410 | 6,057
Fair Value | 8,435 | 6,076
Non-US |  |
Debt Securities, Available-for-sale [Line Items] |  |
Within 1 year, amortized cost | 0 | 3,162
Within 1 year, fair value | 0 | 3,162
Greater than 1 year, less than or equal to 5 years, amortized cost | 2,168 | 2,169
Greater than 1 year, less than or equal to 5 years, fair value | 2,181 | 2,178
Amortized Cost | 2,168 | 5,331
Fair Value | 2,181 | 5,340
US |  |
Debt Securities, Available-for-sale [Line Items] |  |
Within 1 year, amortized cost | 234,545 |
Within 1 year, fair value | 234,941 |
Greater than 1 year, less than or equal to 5 years, amortized cost | 39,171 |
Greater than 1 year, less than or equal to 5 years, fair value | 39,333 |
Amortized Cost | 273,716 |
Fair Value | 274,274 | 344,434
Within 1 year, including cash, amortized cost |  | 326,884
Within 1 year, including cash, fair value |  | 327,076
Greater than 1 year, less than or equal to 5 years, including cash, amortized cost |  | 22,265
Greater than 1 year, less than or equal to 5 years, including cash, fair value |  | 22,353
Including cash, amortized cost |  | 349,149
Including cash, fair value |  | 349,429
Securitization notes receivable and certificates |  |
Debt Securities, Available-for-sale [Line Items] |  |
Within 1 year, amortized cost | 0 | 0
Within 1 year, fair value | 0 | 0
Greater than 1 year, less than or equal to 5 years, amortized cost | 80,792 | 76,279
Greater than 1 year, less than or equal to 5 years, fair value | 80,080 | 75,469
Amortized Cost | 80,792 | 76,279
Fair Value | 80,080 | 75,469
Residual interests in structured transactions |  |
Debt Securities, Available-for-sale [Line Items] |  |
Within 1 year, amortized cost | 0 | 0
Within 1 year, fair value | 0 | 0
Greater than 1 year, less than or equal to 5 years, amortized cost | 4,876 | 2,173
Greater than 1 year, less than or equal to 5 years, fair value | 5,436 | 2,284
Amortized Cost | 4,876 | 2,173
Fair Value | 5,436 | 2,284
Other |  |
Debt Securities, Available-for-sale [Line Items] |  |
Within 1 year, amortized cost | 0 |
Within 1 year, fair value | 0 |
Greater than 1 year, less than or equal to 5 years, amortized cost | 5,000 |
Greater than 1 year, less than or equal to 5 years, fair value | 5,246 |
Amortized Cost | 5,000 |
Fair Value | $ 5,246 |
Commercial Paper, Agency Bonds & US Government Bonds | Cash Equivalents |  |
Debt Securities, Available-for-sale [Line Items] |  |
Fair Value |  | $ 21,100

X
- Definition Debt Securities, Available-for-Sale, Including Cash, Amortized Cost, Excluding Accrued Interest, before Allowance for Credit Loss + References No definition available. + Details
Name: | afrm_DebtSecuritiesAvailableForSaleIncludingCashAmortizedCostExcludingAccruedInterestBeforeAllowanceForCreditLoss
Namespace Prefix: | afrm_
Data Type: | xbrli:monetaryItemType
Balance Type: | debit
Period Type: | instant

X
- Definition Debt Securities, Available-for-Sale, Including Cash, Excluding Accrued Interest + References No definition available. + Details
Name: | afrm_DebtSecuritiesAvailableForSaleIncludingCashExcludingAccruedInterest
Namespace Prefix: | afrm_
Data Type: | xbrli:monetaryItemType
Balance Type: | debit
Period Type: | instant

X
- Definition Debt Securities, Available-for-Sale, Including Cash, Maturity, Allocated and Single Maturity Date, Rolling after One Through Five Years, Amortized Cost + References No definition available. + Details
Name: | afrm_DebtSecuritiesAvailableForSaleIncludingCashMaturityAllocatedAndSingleMaturityDateRollingAfterOneThroughFiveYearsAmortizedCost
Namespace Prefix: | afrm_
Data Type: | xbrli:monetaryItemType
Balance Type: | debit
Period Type: | instant

X
- Definition Debt Securities, Available-for-Sale, Including Cash, Maturity, Allocated and Single Maturity Date, Rolling after One Through Five Years, Fair Value + References No definition available. + Details
Name: | afrm_DebtSecuritiesAvailableForSaleIncludingCashMaturityAllocatedAndSingleMaturityDateRollingAfterOneThroughFiveYearsFairValue
Namespace Prefix: | afrm_
Data Type: | xbrli:monetaryItemType
Balance Type: | debit
Period Type: | instant

X
- Definition Debt Securities, Available-for-Sale, Including Cash, Maturity, Allocated and Single Maturity Date, Rolling within One Year, Amortized Cost + References No definition available. + Details
Name: | afrm_DebtSecuritiesAvailableForSaleIncludingCashMaturityAllocatedAndSingleMaturityDateRollingWithinOneYearAmortizedCost
Namespace Prefix: | afrm_
Data Type: | xbrli:monetaryItemType
Balance Type: | debit
Period Type: | instant

X
- Definition Debt Securities, Available-for-Sale, Including Cash, Maturity, Allocated and Single Maturity Date, Rolling within One Year, Fair Value + References No definition available. + Details
Name: | afrm_DebtSecuritiesAvailableForSaleIncludingCashMaturityAllocatedAndSingleMaturityDateRollingWithinOneYearFairValue
Namespace Prefix: | afrm_
Data Type: | xbrli:monetaryItemType
Balance Type: | debit
Period Type: | instant

X
- Definition Amortized cost of investment in debt security measured at fair value with change in fair value recognized in other comprehensive income (available-for-sale), with single maturity date and allocated without single maturity date, maturing in next rolling fiscal year following latest fiscal year. For interim and annual periods when interim period is reported on rolling approach, from latest statement of financial position date. + References Reference 1: http://www.xbrl.org/2009/role/commonPracticeRef -Topic 320 -SubTopic 10 -Name Accounting Standards Codification -Section 50 -Paragraph 3 -Subparagraph (a) -Publisher FASB -URI https://asc.fasb.org/1943274/2147481800/320-10-50-3 + Details
Name: | us-gaap_AvailableForSaleSecuritiesDebtMaturitiesNextRollingTwelveMonthsAmortizedCostBasis
Namespace Prefix: | us-gaap_
Data Type: | xbrli:monetaryItemType
Balance Type: | debit
Period Type: | instant

X
- Definition Fair value of investment in debt security measured at fair value with change in fair value recognized in other comprehensive income (available-for-sale), with single maturity date and allocated without single maturity date, maturing in next rolling fiscal year following latest fiscal year. For interim and annual periods when interim period is reported on rolling approach, from latest statement of financial position date. + References Reference 1: http://www.xbrl.org/2009/role/commonPracticeRef -Topic 320 -SubTopic 10 -Name Accounting Standards Codification -Section 50 -Paragraph 3 -Subparagraph (a) -Publisher FASB -URI https://asc.fasb.org/1943274/2147481800/320-10-50-3 + Details
Name: | us-gaap_AvailableForSaleSecuritiesDebtMaturitiesNextRollingTwelveMonthsFairValue
Namespace Prefix: | us-gaap_
Data Type: | xbrli:monetaryItemType
Balance Type: | debit
Period Type: | instant

X
- Definition Amortized cost of investment in debt security measured at fair value with change in fair value recognized in other comprehensive income (available-for-sale), with single maturity date and allocated without single maturity date, maturing in next rolling fiscal year through fifth year following latest fiscal year. For interim and annual periods when interim period is reported on rolling approach, from latest statement of financial position date. + References Reference 1: http://www.xbrl.org/2009/role/commonPracticeRef -Topic 320 -SubTopic 10 -Name Accounting Standards Codification -Section 50 -Paragraph 3 -Subparagraph (b) -Publisher FASB -URI https://asc.fasb.org/1943274/2147481800/320-10-50-3 + Details
Name: | us-gaap_AvailableForSaleSecuritiesDebtMaturitiesRollingYearTwoThroughFiveAmortizedCostBasis
Namespace Prefix: | us-gaap_
Data Type: | xbrli:monetaryItemType
Balance Type: | debit
Period Type: | instant

X
- Definition Fair value of investment in debt security, measured at fair value with change in fair value recognized in other comprehensive income (available-for-sale), with single maturity date and allocated without single maturity date, maturing in next rolling fiscal year through fifth year following latest fiscal year. For interim and annual periods when interim period is reported on rolling approach, from latest statement of financial position date. + References Reference 1: http://www.xbrl.org/2009/role/commonPracticeRef -Topic 320 -SubTopic 10 -Name Accounting Standards Codification -Section 50 -Paragraph 3 -Subparagraph (b) -Publisher FASB -URI https://asc.fasb.org/1943274/2147481800/320-10-50-3 + Details
Name: | us-gaap_AvailableForSaleSecuritiesDebtMaturitiesRollingYearTwoThroughFiveFairValue
Namespace Prefix: | us-gaap_
Data Type: | xbrli:monetaryItemType
Balance Type: | debit
Period Type: | instant

X
- Definition Amortized cost excluding accrued interest, before allowance for credit loss, of investment in debt security measured at fair value with change in fair value recognized in other comprehensive income (available-for-sale). + References Reference 1: http://www.xbrl.org/2003/role/disclosureRef -Topic 326 -SubTopic 30 -Name Accounting Standards Codification -Section 45 -Paragraph 1 -Publisher FASB -URI https://asc.fasb.org/1943274/2147479130/326-30-45-1 + Details
Name: | us-gaap_DebtSecuritiesAvailableForSaleAmortizedCostExcludingAccruedInterestBeforeAllowanceForCreditLoss
Namespace Prefix: | us-gaap_
Data Type: | xbrli:monetaryItemType
Balance Type: | debit
Period Type: | instant

X
- Definition Amount excluding accrued interest, of investment in debt security measured at fair value with change in fair value recognized in other comprehensive income (available-for-sale). + References Reference 1: http://www.xbrl.org/2009/role/commonPracticeRef -Topic 326 -SubTopic 30 -Name Accounting Standards Codification -Section 45 -Paragraph 1 -Publisher FASB -URI https://asc.fasb.org/1943274/2147479130/326-30-45-1 + Details
Name: | us-gaap_DebtSecuritiesAvailableForSaleExcludingAccruedInterest
Namespace Prefix: | us-gaap_
Data Type: | xbrli:monetaryItemType
Balance Type: | debit
Period Type: | instant

X
- Definition Line items represent financial concepts included in a table. These concepts are used to disclose reportable information associated with domain members defined in one or many axes to the table. + References Reference 1: http://www.xbrl.org/2003/role/disclosureRef -Topic 320 -SubTopic 10 -Name Accounting Standards Codification -Section 50 -Paragraph 2 -Publisher FASB -URI https://asc.fasb.org/1943274/2147481800/320-10-50-2 Reference 2: http://www.xbrl.org/2003/role/disclosureRef -Topic 320 -SubTopic 10 -Name Accounting Standards Codification -Section 50 -Paragraph 2 -Subparagraph (a) -Publisher FASB -URI https://asc.fasb.org/1943274/2147481800/320-10-50-2 Reference 3: http://www.xbrl.org/2003/role/disclosureRef -Topic 320 -SubTopic 10 -Name Accounting Standards Codification -Section 50 -Paragraph 2 -Subparagraph (aa) -Publisher FASB -URI https://asc.fasb.org/1943274/2147481800/320-10-50-2 Reference 4: http://www.xbrl.org/2003/role/disclosureRef -Topic 320 -SubTopic 10 -Name Accounting Standards Codification -Section 50 -Paragraph 2 -Subparagraph (aaa) -Publisher FASB -URI https://asc.fasb.org/1943274/2147481800/320-10-50-2 Reference 5: http://www.xbrl.org/2003/role/disclosureRef -Topic 320 -SubTopic 10 -Name Accounting Standards Codification -Section 50 -Paragraph 2 -Subparagraph (b) -Publisher FASB -URI https://asc.fasb.org/1943274/2147481800/320-10-50-2 Reference 6: http://www.xbrl.org/2003/role/disclosureRef -Topic 320 -SubTopic 10 -Name Accounting Standards Codification -Section 50 -Paragraph 2 -Subparagraph (c) -Publisher FASB -URI https://asc.fasb.org/1943274/2147481800/320-10-50-2 Reference 7: http://www.xbrl.org/2003/role/disclosureRef -Topic 320 -SubTopic 10 -Name Accounting Standards Codification -Section 50 -Paragraph 2 -Subparagraph (d) -Publisher FASB -URI https://asc.fasb.org/1943274/2147481800/320-10-50-2 Reference 8: http://www.xbrl.org/2003/role/disclosureRef -Topic 320 -SubTopic 10 -Name Accounting Standards Codification -Section 50 -Paragraph 3 -Publisher FASB -URI https://asc.fasb.org/1943274/2147481800/320-10-50-3 Reference 9: http://www.xbrl.org/2003/role/disclosureRef -Topic 320 -SubTopic 10 -Name Accounting Standards Codification -Section 50 -Paragraph 3 -Subparagraph (a) -Publisher FASB -URI https://asc.fasb.org/1943274/2147481800/320-10-50-3 Reference 10: http://www.xbrl.org/2003/role/disclosureRef -Topic 320 -SubTopic 10 -Name Accounting Standards Codification -Section 50 -Paragraph 3 -Subparagraph (b) -Publisher FASB -URI https://asc.fasb.org/1943274/2147481800/320-10-50-3 Reference 11: http://www.xbrl.org/2003/role/disclosureRef -Topic 320 -SubTopic 10 -Name Accounting Standards Codification -Section 50 -Paragraph 3 -Subparagraph (c) -Publisher FASB -URI https://asc.fasb.org/1943274/2147481800/320-10-50-3 Reference 12: http://www.xbrl.org/2003/role/disclosureRef -Topic 320 -SubTopic 10 -Name Accounting Standards Codification -Section 50 -Paragraph 3 -Subparagraph (d) -Publisher FASB -URI https://asc.fasb.org/1943274/2147481800/320-10-50-3 + Details
Name: | us-gaap_ScheduleOfAvailableForSaleSecuritiesLineItems
Namespace Prefix: | us-gaap_
Data Type: | xbrli:stringItemType
Balance Type: | na
Period Type: | duration

X
- Details
Name: | us-gaap_FinancialInstrumentAxis=us-gaap_CertificatesOfDepositMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |

X
- Details
Name: | us-gaap_FinancialInstrumentAxis=us-gaap_CorporateBondSecuritiesMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |

X
- Details
Name: | us-gaap_FinancialInstrumentAxis=us-gaap_CommercialPaperMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |

X
- Details
Name: | us-gaap_FinancialInstrumentAxis=us-gaap_AgencySecuritiesMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |

X
- Details
Name: | us-gaap_FinancialInstrumentAxis=us-gaap_MunicipalBondsMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |

X
- Details
Name: | us-gaap_FinancialInstrumentAxis=afrm_NonUSGovernmentAgenciesDebtSecuritiesMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |

X
- Details
Name: | us-gaap_FinancialInstrumentAxis=us-gaap_USGovernmentAgenciesDebtSecuritiesMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |

X
- Details
Name: | us-gaap_FinancialInstrumentAxis=afrm_SecuritizationNotesReceivableAndCertificatesMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |

X
- Details
Name: | us-gaap_FinancialInstrumentAxis=afrm_ResidualInterestsInStructuredTransactionsMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |

X
- Details
Name: | us-gaap_FinancialInstrumentAxis=us-gaap_OtherDebtSecuritiesMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |

X
- Details
Name: | us-gaap_FinancialInstrumentAxis=afrm_AgencyBondsCommercialPaperAndUSGovernmentBondsMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |

X
- Details
Name: | us-gaap_BalanceSheetLocationAxis=us-gaap_CashEquivalentsMember
Namespace Prefix: |
Data Type: | na
Balance Type: |
Period Type: |