<?xml version="1.0" encoding="UTF-8"?>

<!--XBRL Document Created with the Workiva Platform-->
<!--Copyright 2024 Workiva-->
<!--r:8baaf53c-865d-4131-a2c4-0501d90704b4,g:b576e2b4-795c-4518-9922-681ea7285b85-->
<link:linkbase xmlns:link="http://www.xbrl.org/2003/linkbase" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xsi:schemaLocation="http://www.xbrl.org/2003/linkbase http://www.xbrl.org/2003/xbrl-linkbase-2003-12-31.xsd">
  <link:roleRef roleURI="http://www.fanniemae.com/role/CondensedConsolidatedBalanceSheetsUnaudited" xlink:type="simple" xlink:href="fnm-20240930.xsd#CondensedConsolidatedBalanceSheetsUnaudited"/>
  <link:calculationLink xlink:role="http://www.fanniemae.com/role/CondensedConsolidatedBalanceSheetsUnaudited" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_Assets_7c119970-9939-4f58-b4d0-8a34b701bc8c" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_Assets"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_CashAndCashEquivalentsAtCarryingValue_6b1a45f6-66a5-4796-80a1-14a65567ee9e" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_CashAndCashEquivalentsAtCarryingValue"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_7c119970-9939-4f58-b4d0-8a34b701bc8c" xlink:to="loc_us-gaap_CashAndCashEquivalentsAtCarryingValue_6b1a45f6-66a5-4796-80a1-14a65567ee9e" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_RestrictedCashAndCashEquivalents_1106d19d-d160-497e-8010-72c58b5f44a0" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_RestrictedCashAndCashEquivalents"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_7c119970-9939-4f58-b4d0-8a34b701bc8c" xlink:to="loc_us-gaap_RestrictedCashAndCashEquivalents_1106d19d-d160-497e-8010-72c58b5f44a0" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_MarketableSecurities_ec9565f5-dcc3-47e1-892a-391f08ab8879" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_MarketableSecurities"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_7c119970-9939-4f58-b4d0-8a34b701bc8c" xlink:to="loc_us-gaap_MarketableSecurities_ec9565f5-dcc3-47e1-892a-391f08ab8879" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_MortgageLoansOnRealEstateCommercialAndConsumerNet_2268e4b4-cd0f-4105-bccd-afe10fb992f3" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_MortgageLoansOnRealEstateCommercialAndConsumerNet"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_7c119970-9939-4f58-b4d0-8a34b701bc8c" xlink:to="loc_us-gaap_MortgageLoansOnRealEstateCommercialAndConsumerNet_2268e4b4-cd0f-4105-bccd-afe10fb992f3" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_fnm_AdvanceToLender_037e682b-e694-4ce3-9612-cdb7a224cdbd" xlink:href="fnm-20240930.xsd#fnm_AdvanceToLender"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_7c119970-9939-4f58-b4d0-8a34b701bc8c" xlink:to="loc_fnm_AdvanceToLender_037e682b-e694-4ce3-9612-cdb7a224cdbd" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableAccruedInterestAfterAllowanceForCreditLoss_31478398-3cf4-44f1-9659-307285d0b3db" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FinancingReceivableAccruedInterestAfterAllowanceForCreditLoss"/>
    <link:calculationArc order="6" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_7c119970-9939-4f58-b4d0-8a34b701bc8c" xlink:to="loc_us-gaap_FinancingReceivableAccruedInterestAfterAllowanceForCreditLoss_31478398-3cf4-44f1-9659-307285d0b3db" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DeferredIncomeTaxAssetsNet_6686e72f-1954-4e1a-8c63-e8d966c26eff" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DeferredIncomeTaxAssetsNet"/>
    <link:calculationArc order="7" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_7c119970-9939-4f58-b4d0-8a34b701bc8c" xlink:to="loc_us-gaap_DeferredIncomeTaxAssetsNet_6686e72f-1954-4e1a-8c63-e8d966c26eff" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherAssets_8deb3a9b-d957-4efe-9d0e-82f56bb86537" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherAssets"/>
    <link:calculationArc order="8" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_7c119970-9939-4f58-b4d0-8a34b701bc8c" xlink:to="loc_us-gaap_OtherAssets_8deb3a9b-d957-4efe-9d0e-82f56bb86537" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_SecuritiesPurchasedUnderAgreementsToResell_0d5d0340-42c0-4557-924e-2c7b41975589" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_SecuritiesPurchasedUnderAgreementsToResell"/>
    <link:calculationArc order="9" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Assets_7c119970-9939-4f58-b4d0-8a34b701bc8c" xlink:to="loc_us-gaap_SecuritiesPurchasedUnderAgreementsToResell_0d5d0340-42c0-4557-924e-2c7b41975589" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_Liabilities_1b45846a-73e5-4e4e-b45b-a260a027d77c" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_Liabilities"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DebtAndCapitalLeaseObligations_8881462a-f1a2-47cf-9968-e159e223c9a5" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DebtAndCapitalLeaseObligations"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Liabilities_1b45846a-73e5-4e4e-b45b-a260a027d77c" xlink:to="loc_us-gaap_DebtAndCapitalLeaseObligations_8881462a-f1a2-47cf-9968-e159e223c9a5" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherLiabilities_cf697e50-fea0-4fc7-bf56-e64c2cc7c72d" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherLiabilities"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Liabilities_1b45846a-73e5-4e4e-b45b-a260a027d77c" xlink:to="loc_us-gaap_OtherLiabilities_cf697e50-fea0-4fc7-bf56-e64c2cc7c72d" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestPayableCurrentAndNoncurrent_73b7c1f3-868a-4b04-b343-ddd6f42ca62d" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_InterestPayableCurrentAndNoncurrent"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_Liabilities_1b45846a-73e5-4e4e-b45b-a260a027d77c" xlink:to="loc_us-gaap_InterestPayableCurrentAndNoncurrent_73b7c1f3-868a-4b04-b343-ddd6f42ca62d" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableExcludingAccruedInterestAfterAllowanceForCreditLoss_025b039b-4ac8-4514-a4e5-d1f1142b6aa5" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FinancingReceivableExcludingAccruedInterestAfterAllowanceForCreditLoss"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableExcludingAccruedInterestBeforeAllowanceForCreditLoss_bc05396f-691f-4b2a-9f62-0a112dd43c94" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FinancingReceivableExcludingAccruedInterestBeforeAllowanceForCreditLoss"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_FinancingReceivableExcludingAccruedInterestAfterAllowanceForCreditLoss_025b039b-4ac8-4514-a4e5-d1f1142b6aa5" xlink:to="loc_us-gaap_FinancingReceivableExcludingAccruedInterestBeforeAllowanceForCreditLoss_bc05396f-691f-4b2a-9f62-0a112dd43c94" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableAllowanceForCreditLossExcludingAccruedInterest_c433734c-c3ef-4a4d-b8be-9d9b713caab0" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FinancingReceivableAllowanceForCreditLossExcludingAccruedInterest"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_FinancingReceivableExcludingAccruedInterestAfterAllowanceForCreditLoss_025b039b-4ac8-4514-a4e5-d1f1142b6aa5" xlink:to="loc_us-gaap_FinancingReceivableAllowanceForCreditLossExcludingAccruedInterest_c433734c-c3ef-4a4d-b8be-9d9b713caab0" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LiabilitiesAndStockholdersEquity_0dd1446c-c5d3-4d6c-a2b9-b3ad86ba281e" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_LiabilitiesAndStockholdersEquity"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_Liabilities_674893a9-14c4-46e8-b658-2eda690657c7" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_Liabilities"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquity_0dd1446c-c5d3-4d6c-a2b9-b3ad86ba281e" xlink:to="loc_us-gaap_Liabilities_674893a9-14c4-46e8-b658-2eda690657c7" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_CommitmentsAndContingencies_9c91a2c0-0d04-4417-ad91-00167cb43710" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_CommitmentsAndContingencies"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquity_0dd1446c-c5d3-4d6c-a2b9-b3ad86ba281e" xlink:to="loc_us-gaap_CommitmentsAndContingencies_9c91a2c0-0d04-4417-ad91-00167cb43710" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_StockholdersEquity_29f70b48-b5ab-45a8-8c74-c72b1ca4d942" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_StockholdersEquity"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesAndStockholdersEquity_0dd1446c-c5d3-4d6c-a2b9-b3ad86ba281e" xlink:to="loc_us-gaap_StockholdersEquity_29f70b48-b5ab-45a8-8c74-c72b1ca4d942" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_MortgageLoansOnRealEstateCommercialAndConsumerNet_2d46851b-fdff-42ee-829c-97a8a595be29" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_MortgageLoansOnRealEstateCommercialAndConsumerNet"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LoansReceivableHeldForSaleAmount_f8670efb-6a48-4906-bf60-bd37d9491419" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_LoansReceivableHeldForSaleAmount"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_MortgageLoansOnRealEstateCommercialAndConsumerNet_2d46851b-fdff-42ee-829c-97a8a595be29" xlink:to="loc_us-gaap_LoansReceivableHeldForSaleAmount_f8670efb-6a48-4906-bf60-bd37d9491419" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableExcludingAccruedInterestAfterAllowanceForCreditLoss_42a901e5-42a2-4f37-985c-d79992ab9460" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FinancingReceivableExcludingAccruedInterestAfterAllowanceForCreditLoss"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_MortgageLoansOnRealEstateCommercialAndConsumerNet_2d46851b-fdff-42ee-829c-97a8a595be29" xlink:to="loc_us-gaap_FinancingReceivableExcludingAccruedInterestAfterAllowanceForCreditLoss_42a901e5-42a2-4f37-985c-d79992ab9460" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_StockholdersEquity_cb4bc510-1ab5-43a0-a6a5-4f5ae6ba26d7" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_StockholdersEquity"/>
    <link:loc xlink:type="locator" xlink:label="loc_fnm_SeniorPreferredStockValue_7fee5abf-df5c-4690-b244-7a3626ba6d15" xlink:href="fnm-20240930.xsd#fnm_SeniorPreferredStockValue"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_StockholdersEquity_cb4bc510-1ab5-43a0-a6a5-4f5ae6ba26d7" xlink:to="loc_fnm_SeniorPreferredStockValue_7fee5abf-df5c-4690-b244-7a3626ba6d15" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PreferredStockValue_8f9df304-3cce-424f-b457-7c04ef3a2974" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_PreferredStockValue"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_StockholdersEquity_cb4bc510-1ab5-43a0-a6a5-4f5ae6ba26d7" xlink:to="loc_us-gaap_PreferredStockValue_8f9df304-3cce-424f-b457-7c04ef3a2974" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_CommonStockValue_7e7c2ddf-9a7e-4aa6-ad0d-6599db7315b7" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_CommonStockValue"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_StockholdersEquity_cb4bc510-1ab5-43a0-a6a5-4f5ae6ba26d7" xlink:to="loc_us-gaap_CommonStockValue_7e7c2ddf-9a7e-4aa6-ad0d-6599db7315b7" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_RetainedEarningsAccumulatedDeficit_b2b51ff3-7c67-433d-b4c6-8e6746b072ee" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_RetainedEarningsAccumulatedDeficit"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_StockholdersEquity_cb4bc510-1ab5-43a0-a6a5-4f5ae6ba26d7" xlink:to="loc_us-gaap_RetainedEarningsAccumulatedDeficit_b2b51ff3-7c67-433d-b4c6-8e6746b072ee" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossNetOfTax_7bd9e05d-3d4f-47dc-9722-41f9e9d34a07" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_AccumulatedOtherComprehensiveIncomeLossNetOfTax"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_StockholdersEquity_cb4bc510-1ab5-43a0-a6a5-4f5ae6ba26d7" xlink:to="loc_us-gaap_AccumulatedOtherComprehensiveIncomeLossNetOfTax_7bd9e05d-3d4f-47dc-9722-41f9e9d34a07" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_TreasuryStockValue_6fd767b6-d11c-46a7-b8f7-0de24310daff" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_TreasuryStockValue"/>
    <link:calculationArc order="6" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_StockholdersEquity_cb4bc510-1ab5-43a0-a6a5-4f5ae6ba26d7" xlink:to="loc_us-gaap_TreasuryStockValue_6fd767b6-d11c-46a7-b8f7-0de24310daff" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.fanniemae.com/role/CondensedConsolidatedStatementsofOperationsandComprehensiveIncomeUnaudited" xlink:type="simple" xlink:href="fnm-20240930.xsd#CondensedConsolidatedStatementsofOperationsandComprehensiveIncomeUnaudited"/>
  <link:calculationLink xlink:role="http://www.fanniemae.com/role/CondensedConsolidatedStatementsofOperationsandComprehensiveIncomeUnaudited" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ComprehensiveIncomeNetOfTax_4a54c0ed-6b4c-483e-b633-fe71698f887b" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_ComprehensiveIncomeNetOfTax"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetIncomeLoss_459304db-6731-43d7-b176-7fc357a0ebd1" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_NetIncomeLoss"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_ComprehensiveIncomeNetOfTax_4a54c0ed-6b4c-483e-b633-fe71698f887b" xlink:to="loc_us-gaap_NetIncomeLoss_459304db-6731-43d7-b176-7fc357a0ebd1" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTax_ad3dcdc0-d5e5-4172-b778-b7021e91763e" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeLossNetOfTax"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_ComprehensiveIncomeNetOfTax_4a54c0ed-6b4c-483e-b633-fe71698f887b" xlink:to="loc_us-gaap_OtherComprehensiveIncomeLossNetOfTax_ad3dcdc0-d5e5-4172-b778-b7021e91763e" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestExpenseOperating_4c0ffab9-6936-4d78-8e0c-bb55b93f73a0" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_InterestExpenseOperating"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestExpenseShortTermBorrowings_0ae39880-d7cc-4ea2-ba7d-26d20b0d2163" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_InterestExpenseShortTermBorrowings"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_InterestExpenseOperating_4c0ffab9-6936-4d78-8e0c-bb55b93f73a0" xlink:to="loc_us-gaap_InterestExpenseShortTermBorrowings_0ae39880-d7cc-4ea2-ba7d-26d20b0d2163" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestExpenseLongTermDebt_b1c7f1aa-2249-4035-a731-a504b12c997b" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_InterestExpenseLongTermDebt"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_InterestExpenseOperating_4c0ffab9-6936-4d78-8e0c-bb55b93f73a0" xlink:to="loc_us-gaap_InterestExpenseLongTermDebt_b1c7f1aa-2249-4035-a731-a504b12c997b" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetIncomeLossAvailableToCommonStockholdersDiluted_bcc60a4b-d744-4152-a203-c10278115b48" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_NetIncomeLossAvailableToCommonStockholdersDiluted"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetIncomeLossAvailableToCommonStockholdersBasic_c260cc3c-478a-4376-a9ea-055c4ea9148d" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_NetIncomeLossAvailableToCommonStockholdersBasic"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetIncomeLossAvailableToCommonStockholdersDiluted_bcc60a4b-d744-4152-a203-c10278115b48" xlink:to="loc_us-gaap_NetIncomeLossAvailableToCommonStockholdersBasic_c260cc3c-478a-4376-a9ea-055c4ea9148d" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetIncomeLoss_5c178ee5-e9f3-475a-9cb1-c6eeb31518ff" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_NetIncomeLoss"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_7abffb14-272c-46a6-8d39-38a36ef690b2" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetIncomeLoss_5c178ee5-e9f3-475a-9cb1-c6eeb31518ff" xlink:to="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_7abffb14-272c-46a6-8d39-38a36ef690b2" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncomeTaxExpenseBenefit_04f71ff0-cb65-409b-b01d-224fded6df6f" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_IncomeTaxExpenseBenefit"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetIncomeLoss_5c178ee5-e9f3-475a-9cb1-c6eeb31518ff" xlink:to="loc_us-gaap_IncomeTaxExpenseBenefit_04f71ff0-cb65-409b-b01d-224fded6df6f" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestIncomeExpenseNet_455441cf-0feb-40fc-ad6e-8e9a6b40581a" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_InterestIncomeExpenseNet"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestAndDividendIncomeOperating_2798481d-c702-4e18-bafe-4e7a1206d69f" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_InterestAndDividendIncomeOperating"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_InterestIncomeExpenseNet_455441cf-0feb-40fc-ad6e-8e9a6b40581a" xlink:to="loc_us-gaap_InterestAndDividendIncomeOperating_2798481d-c702-4e18-bafe-4e7a1206d69f" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestExpenseOperating_7ec509d4-6825-413c-92d6-649469a05efb" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_InterestExpenseOperating"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_InterestIncomeExpenseNet_455441cf-0feb-40fc-ad6e-8e9a6b40581a" xlink:to="loc_us-gaap_InterestExpenseOperating_7ec509d4-6825-413c-92d6-649469a05efb" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestAndDividendIncomeOperating_90302db4-b31a-461c-9d1f-a7dcda7e7516" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_InterestAndDividendIncomeOperating"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestIncomeDebtSecuritiesOperating_c64f4307-dc51-4560-8ab0-bda6cb968e8b" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_InterestIncomeDebtSecuritiesOperating"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_InterestAndDividendIncomeOperating_90302db4-b31a-461c-9d1f-a7dcda7e7516" xlink:to="loc_us-gaap_InterestIncomeDebtSecuritiesOperating_c64f4307-dc51-4560-8ab0-bda6cb968e8b" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestAndFeeIncomeLoansAndLeases_9901e773-e615-48d4-9c02-45fa688e066f" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_InterestAndFeeIncomeLoansAndLeases"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_InterestAndDividendIncomeOperating_90302db4-b31a-461c-9d1f-a7dcda7e7516" xlink:to="loc_us-gaap_InterestAndFeeIncomeLoansAndLeases_9901e773-e615-48d4-9c02-45fa688e066f" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherInterestAndDividendIncome_4bc75014-2ee9-48ec-8a79-7296074baf14" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherInterestAndDividendIncome"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_InterestAndDividendIncomeOperating_90302db4-b31a-461c-9d1f-a7dcda7e7516" xlink:to="loc_us-gaap_OtherInterestAndDividendIncome_4bc75014-2ee9-48ec-8a79-7296074baf14" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NoninterestIncome_81b47adc-8f4e-4dab-ae65-22e630be4de0" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_NoninterestIncome"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_GainLossOnInvestments_95d0a06b-59da-4644-8860-9dd0d13babc5" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_GainLossOnInvestments"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NoninterestIncome_81b47adc-8f4e-4dab-ae65-22e630be4de0" xlink:to="loc_us-gaap_GainLossOnInvestments_95d0a06b-59da-4644-8860-9dd0d13babc5" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FairValueOptionChangesInFairValueGainLoss1_6596ece9-d370-4772-bbed-dc0414c68e22" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FairValueOptionChangesInFairValueGainLoss1"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NoninterestIncome_81b47adc-8f4e-4dab-ae65-22e630be4de0" xlink:to="loc_us-gaap_FairValueOptionChangesInFairValueGainLoss1_6596ece9-d370-4772-bbed-dc0414c68e22" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NoninterestIncomeOtherOperatingIncome_dfb77c26-1e69-40fc-b2dc-a1552b36e6f5" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_NoninterestIncomeOtherOperatingIncome"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NoninterestIncome_81b47adc-8f4e-4dab-ae65-22e630be4de0" xlink:to="loc_us-gaap_NoninterestIncomeOtherOperatingIncome_dfb77c26-1e69-40fc-b2dc-a1552b36e6f5" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_GeneralAndAdministrativeExpense_1a2809f0-05c9-4163-804b-1944ad2c8df3" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_GeneralAndAdministrativeExpense"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ProfessionalAndContractServicesExpense_d032db1d-a584-41a4-b1e4-1b7c384936c5" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_ProfessionalAndContractServicesExpense"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_GeneralAndAdministrativeExpense_1a2809f0-05c9-4163-804b-1944ad2c8df3" xlink:to="loc_us-gaap_ProfessionalAndContractServicesExpense_d032db1d-a584-41a4-b1e4-1b7c384936c5" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LaborAndRelatedExpense_41ef1ab6-09a6-4dbc-8492-be66575bcaa1" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_LaborAndRelatedExpense"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_GeneralAndAdministrativeExpense_1a2809f0-05c9-4163-804b-1944ad2c8df3" xlink:to="loc_us-gaap_LaborAndRelatedExpense_41ef1ab6-09a6-4dbc-8492-be66575bcaa1" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherGeneralAndAdministrativeExpense_2052c5ab-b583-4798-8ba0-9ee5b549261c" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherGeneralAndAdministrativeExpense"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_GeneralAndAdministrativeExpense_1a2809f0-05c9-4163-804b-1944ad2c8df3" xlink:to="loc_us-gaap_OtherGeneralAndAdministrativeExpense_2052c5ab-b583-4798-8ba0-9ee5b549261c" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetIncomeLossAvailableToCommonStockholdersBasic_46695694-da0e-4f72-b62e-fc6330e5a4bd" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_NetIncomeLossAvailableToCommonStockholdersBasic"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetIncomeLoss_997efaea-67fe-4673-8ba7-847257a21a49" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_NetIncomeLoss"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetIncomeLossAvailableToCommonStockholdersBasic_46695694-da0e-4f72-b62e-fc6330e5a4bd" xlink:to="loc_us-gaap_NetIncomeLoss_997efaea-67fe-4673-8ba7-847257a21a49" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PreferredStockDividendsAndOtherAdjustments_2f54366a-a9e6-4936-accc-71275897195f" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_PreferredStockDividendsAndOtherAdjustments"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetIncomeLossAvailableToCommonStockholdersBasic_46695694-da0e-4f72-b62e-fc6330e5a4bd" xlink:to="loc_us-gaap_PreferredStockDividendsAndOtherAdjustments_2f54366a-a9e6-4936-accc-71275897195f" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NoninterestExpense_9cfda029-b463-473a-9b08-cc8332f13760" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_NoninterestExpense"/>
    <link:loc xlink:type="locator" xlink:label="loc_fnm_SingleFamilyGuarantyFeeTemporaryPayrollTaxCutContinuationActOf2011_1dc0e887-e379-409d-bda2-1d527e695f33" xlink:href="fnm-20240930.xsd#fnm_SingleFamilyGuarantyFeeTemporaryPayrollTaxCutContinuationActOf2011"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NoninterestExpense_9cfda029-b463-473a-9b08-cc8332f13760" xlink:to="loc_fnm_SingleFamilyGuarantyFeeTemporaryPayrollTaxCutContinuationActOf2011_1dc0e887-e379-409d-bda2-1d527e695f33" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherNoninterestExpense_f891883b-07bf-4d5a-9598-19468b5dc7b3" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherNoninterestExpense"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NoninterestExpense_9cfda029-b463-473a-9b08-cc8332f13760" xlink:to="loc_us-gaap_OtherNoninterestExpense_f891883b-07bf-4d5a-9598-19468b5dc7b3" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_fnm_ChangeInExpectedCreditEnhancementRecoveries_2afaba1e-342a-44fd-8e6d-ba40aaa80ef7" xlink:href="fnm-20240930.xsd#fnm_ChangeInExpectedCreditEnhancementRecoveries"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NoninterestExpense_9cfda029-b463-473a-9b08-cc8332f13760" xlink:to="loc_fnm_ChangeInExpectedCreditEnhancementRecoveries_2afaba1e-342a-44fd-8e6d-ba40aaa80ef7" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_fnm_CreditEnhancementExpense_1fa2d54e-fa79-4f4c-83d4-b379f2be455a" xlink:href="fnm-20240930.xsd#fnm_CreditEnhancementExpense"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NoninterestExpense_9cfda029-b463-473a-9b08-cc8332f13760" xlink:to="loc_fnm_CreditEnhancementExpense_1fa2d54e-fa79-4f4c-83d4-b379f2be455a" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_GeneralAndAdministrativeExpense_d858eb7f-f460-440f-b885-061945c581c1" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_GeneralAndAdministrativeExpense"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NoninterestExpense_9cfda029-b463-473a-9b08-cc8332f13760" xlink:to="loc_us-gaap_GeneralAndAdministrativeExpense_d858eb7f-f460-440f-b885-061945c581c1" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestIncomeExpenseAfterProvisionForLoanLoss_58b687ac-8471-49fd-96fd-fed5ccb54eff" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_InterestIncomeExpenseAfterProvisionForLoanLoss"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestIncomeExpenseNet_e831c1c4-c50b-4ead-8caa-a9775edaf0c9" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_InterestIncomeExpenseNet"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_InterestIncomeExpenseAfterProvisionForLoanLoss_58b687ac-8471-49fd-96fd-fed5ccb54eff" xlink:to="loc_us-gaap_InterestIncomeExpenseNet_e831c1c4-c50b-4ead-8caa-a9775edaf0c9" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ProvisionForLoanLeaseAndOtherLosses_9cf03486-cd5f-465b-99da-96dc7dfe3e33" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_ProvisionForLoanLeaseAndOtherLosses"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_InterestIncomeExpenseAfterProvisionForLoanLoss_58b687ac-8471-49fd-96fd-fed5ccb54eff" xlink:to="loc_us-gaap_ProvisionForLoanLeaseAndOtherLosses_9cf03486-cd5f-465b-99da-96dc7dfe3e33" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.fanniemae.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited" xlink:type="simple" xlink:href="fnm-20240930.xsd#CondensedConsolidatedStatementsofCashFlowsUnaudited"/>
  <link:calculationLink xlink:role="http://www.fanniemae.com/role/CondensedConsolidatedStatementsofCashFlowsUnaudited" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_39e0628e-c274-4820-9aca-3ae0f01c929a" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_NetCashProvidedByUsedInInvestingActivities"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ProceedsFromPrincipalRepaymentsOnLoansAndLeasesHeldForInvestment_33726818-b474-4fb6-a4d2-aba0a6a711cd" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_ProceedsFromPrincipalRepaymentsOnLoansAndLeasesHeldForInvestment"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_39e0628e-c274-4820-9aca-3ae0f01c929a" xlink:to="loc_us-gaap_ProceedsFromPrincipalRepaymentsOnLoansAndLeasesHeldForInvestment_33726818-b474-4fb6-a4d2-aba0a6a711cd" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_fnm_PaymentsForAdvancesToLenders_7273668c-96b5-4f09-9a8e-c500507ab535" xlink:href="fnm-20240930.xsd#fnm_PaymentsForAdvancesToLenders"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_39e0628e-c274-4820-9aca-3ae0f01c929a" xlink:to="loc_fnm_PaymentsForAdvancesToLenders_7273668c-96b5-4f09-9a8e-c500507ab535" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ProceedsFromSaleOfLoansAndLeasesHeldForInvestment_a606e8f7-5822-4de5-8eb6-4762a99e2302" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_ProceedsFromSaleOfLoansAndLeasesHeldForInvestment"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_39e0628e-c274-4820-9aca-3ae0f01c929a" xlink:to="loc_us-gaap_ProceedsFromSaleOfLoansAndLeasesHeldForInvestment_a606e8f7-5822-4de5-8eb6-4762a99e2302" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ProceedsFromPaymentsForFederalFundsSoldAndSecuritiesPurchasedUnderAgreementsToResellNet_99812441-ffcd-4023-a68a-207383885767" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_ProceedsFromPaymentsForFederalFundsSoldAndSecuritiesPurchasedUnderAgreementsToResellNet"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_39e0628e-c274-4820-9aca-3ae0f01c929a" xlink:to="loc_us-gaap_ProceedsFromPaymentsForFederalFundsSoldAndSecuritiesPurchasedUnderAgreementsToResellNet_99812441-ffcd-4023-a68a-207383885767" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PaymentsToAcquireLoansHeldForInvestment_8610b3b6-a605-4d23-af27-f78f81148d15" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_PaymentsToAcquireLoansHeldForInvestment"/>
    <link:calculationArc order="5" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_39e0628e-c274-4820-9aca-3ae0f01c929a" xlink:to="loc_us-gaap_PaymentsToAcquireLoansHeldForInvestment_8610b3b6-a605-4d23-af27-f78f81148d15" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ProceedsFromSaleOfForeclosedAssets_1440a0b4-843e-4241-a431-209d99b5c833" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_ProceedsFromSaleOfForeclosedAssets"/>
    <link:calculationArc order="6" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_39e0628e-c274-4820-9aca-3ae0f01c929a" xlink:to="loc_us-gaap_ProceedsFromSaleOfForeclosedAssets_1440a0b4-843e-4241-a431-209d99b5c833" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_PaymentsForProceedsFromOtherInvestingActivities_36a90cd8-73fb-4c4c-8b88-aa7d0c686b75" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_PaymentsForProceedsFromOtherInvestingActivities"/>
    <link:calculationArc order="7" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_39e0628e-c274-4820-9aca-3ae0f01c929a" xlink:to="loc_us-gaap_PaymentsForProceedsFromOtherInvestingActivities_36a90cd8-73fb-4c4c-8b88-aa7d0c686b75" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseExcludingExchangeRateEffect_c5e2803e-f59d-4b05-b672-1c11d9a32d92" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseExcludingExchangeRateEffect"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_d7be49b8-d6af-4aff-8f39-a2ae4d7e7d99" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_NetCashProvidedByUsedInOperatingActivities"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseExcludingExchangeRateEffect_c5e2803e-f59d-4b05-b672-1c11d9a32d92" xlink:to="loc_us-gaap_NetCashProvidedByUsedInOperatingActivities_d7be49b8-d6af-4aff-8f39-a2ae4d7e7d99" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_059b4929-339d-4418-9901-5c3cedad0d06" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_NetCashProvidedByUsedInInvestingActivities"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseExcludingExchangeRateEffect_c5e2803e-f59d-4b05-b672-1c11d9a32d92" xlink:to="loc_us-gaap_NetCashProvidedByUsedInInvestingActivities_059b4929-339d-4418-9901-5c3cedad0d06" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_c00f9e92-e389-46fa-909f-881e282bbc38" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_NetCashProvidedByUsedInFinancingActivities"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_CashCashEquivalentsRestrictedCashAndRestrictedCashEquivalentsPeriodIncreaseDecreaseExcludingExchangeRateEffect_c5e2803e-f59d-4b05-b672-1c11d9a32d92" xlink:to="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_c00f9e92-e389-46fa-909f-881e282bbc38" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_29e469d2-bc5a-4fd0-a280-84129bd7e3be" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_NetCashProvidedByUsedInFinancingActivities"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_RepaymentsOfDebt_3eec4d46-812d-432f-bd79-9c67dd4d4d53" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_RepaymentsOfDebt"/>
    <link:calculationArc order="1" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_29e469d2-bc5a-4fd0-a280-84129bd7e3be" xlink:to="loc_us-gaap_RepaymentsOfDebt_3eec4d46-812d-432f-bd79-9c67dd4d4d53" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ProceedsFromIssuanceOfDebt_559c686e-3552-42cd-a519-ebf2e81bdde1" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_ProceedsFromIssuanceOfDebt"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NetCashProvidedByUsedInFinancingActivities_29e469d2-bc5a-4fd0-a280-84129bd7e3be" xlink:to="loc_us-gaap_ProceedsFromIssuanceOfDebt_559c686e-3552-42cd-a519-ebf2e81bdde1" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.fanniemae.com/role/CondensedConsolidatedStatementsofChangesinEquityUnaudited" xlink:type="simple" xlink:href="fnm-20240930.xsd#CondensedConsolidatedStatementsofChangesinEquityUnaudited"/>
  <link:calculationLink xlink:role="http://www.fanniemae.com/role/CondensedConsolidatedStatementsofChangesinEquityUnaudited" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ComprehensiveIncomeNetOfTaxIncludingPortionAttributableToNoncontrollingInterest_96fc785e-09a8-4af0-9dd0-67e903e5e358" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_ComprehensiveIncomeNetOfTaxIncludingPortionAttributableToNoncontrollingInterest"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NetIncomeLoss_2968613c-9949-4573-957b-d779fe6b19c6" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_NetIncomeLoss"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_ComprehensiveIncomeNetOfTaxIncludingPortionAttributableToNoncontrollingInterest_96fc785e-09a8-4af0-9dd0-67e903e5e358" xlink:to="loc_us-gaap_NetIncomeLoss_2968613c-9949-4573-957b-d779fe6b19c6" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeOtherNetOfTax_cfa2351c-671b-484f-84cb-81876829141f" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeOtherNetOfTax"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_ComprehensiveIncomeNetOfTaxIncludingPortionAttributableToNoncontrollingInterest_96fc785e-09a8-4af0-9dd0-67e903e5e358" xlink:to="loc_us-gaap_OtherComprehensiveIncomeOtherNetOfTax_cfa2351c-671b-484f-84cb-81876829141f" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherComprehensiveIncomeUnrealizedHoldingGainLossOnSecuritiesArisingDuringPeriodNetOfTax_7dc27d60-441d-40df-8ca7-6b9dc23875c2" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherComprehensiveIncomeUnrealizedHoldingGainLossOnSecuritiesArisingDuringPeriodNetOfTax"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_ComprehensiveIncomeNetOfTaxIncludingPortionAttributableToNoncontrollingInterest_96fc785e-09a8-4af0-9dd0-67e903e5e358" xlink:to="loc_us-gaap_OtherComprehensiveIncomeUnrealizedHoldingGainLossOnSecuritiesArisingDuringPeriodNetOfTax_7dc27d60-441d-40df-8ca7-6b9dc23875c2" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.fanniemae.com/role/ConsolidationsandTransfersofFinancialAssetsUnconsolidatedVIEsDetails" xlink:type="simple" xlink:href="fnm-20240930.xsd#ConsolidationsandTransfersofFinancialAssetsUnconsolidatedVIEsDetails"/>
  <link:calculationLink xlink:role="http://www.fanniemae.com/role/ConsolidationsandTransfersofFinancialAssetsUnconsolidatedVIEsDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AssetsNet_8285c374-cd01-4d84-8379-a9997d55d3b1" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_AssetsNet"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherLiabilities_b2bfaf11-1cef-452e-ade2-9816488c215f" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherLiabilities"/>
    <link:calculationArc order="1" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AssetsNet_8285c374-cd01-4d84-8379-a9997d55d3b1" xlink:to="loc_us-gaap_OtherLiabilities_b2bfaf11-1cef-452e-ade2-9816488c215f" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherAssets_e0232928-321c-4485-84ca-a9693601f7a6" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherAssets"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AssetsNet_8285c374-cd01-4d84-8379-a9997d55d3b1" xlink:to="loc_us-gaap_OtherAssets_e0232928-321c-4485-84ca-a9693601f7a6" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_MarketableSecurities_387b25f7-0489-45bc-98bb-e12e50a64070" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_MarketableSecurities"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AssetsNet_8285c374-cd01-4d84-8379-a9997d55d3b1" xlink:to="loc_us-gaap_MarketableSecurities_387b25f7-0489-45bc-98bb-e12e50a64070" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.fanniemae.com/role/MortgageLoansLoansinMortgagePortfolioDetails" xlink:type="simple" xlink:href="fnm-20240930.xsd#MortgageLoansLoansinMortgagePortfolioDetails"/>
  <link:calculationLink xlink:role="http://www.fanniemae.com/role/MortgageLoansLoansinMortgagePortfolioDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_MortgageLoansOnRealEstateCommercialAndConsumerNet_fc725fa4-9dbe-44f8-b5ba-742f95256272" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_MortgageLoansOnRealEstateCommercialAndConsumerNet"/>
    <link:loc xlink:type="locator" xlink:label="loc_fnm_MortgageLoansOnRealEstateUnpaidPrincipalBalance_fc731ee5-cc7c-46dc-8a51-9730aaba9272" xlink:href="fnm-20240930.xsd#fnm_MortgageLoansOnRealEstateUnpaidPrincipalBalance"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_MortgageLoansOnRealEstateCommercialAndConsumerNet_fc725fa4-9dbe-44f8-b5ba-742f95256272" xlink:to="loc_fnm_MortgageLoansOnRealEstateUnpaidPrincipalBalance_fc731ee5-cc7c-46dc-8a51-9730aaba9272" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_fnm_MortgageLoansCostBasisAndFairValueAdjustmentsNet_c6d9815e-1b30-420e-ae1e-d07f75ad613c" xlink:href="fnm-20240930.xsd#fnm_MortgageLoansCostBasisAndFairValueAdjustmentsNet"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_MortgageLoansOnRealEstateCommercialAndConsumerNet_fc725fa4-9dbe-44f8-b5ba-742f95256272" xlink:to="loc_fnm_MortgageLoansCostBasisAndFairValueAdjustmentsNet_c6d9815e-1b30-420e-ae1e-d07f75ad613c" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableAllowanceForCreditLossExcludingAccruedInterest_f1c9e376-de6f-4c6a-861f-3916c5d7d45b" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FinancingReceivableAllowanceForCreditLossExcludingAccruedInterest"/>
    <link:calculationArc order="3" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_MortgageLoansOnRealEstateCommercialAndConsumerNet_fc725fa4-9dbe-44f8-b5ba-742f95256272" xlink:to="loc_us-gaap_FinancingReceivableAllowanceForCreditLossExcludingAccruedInterest_f1c9e376-de6f-4c6a-861f-3916c5d7d45b" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.fanniemae.com/role/MortgageLoansCreditQualityIndicatorsSFDetails" xlink:type="simple" xlink:href="fnm-20240930.xsd#MortgageLoansCreditQualityIndicatorsSFDetails"/>
  <link:calculationLink xlink:role="http://www.fanniemae.com/role/MortgageLoansCreditQualityIndicatorsSFDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableRevolvingWriteoff_e9a8b983-df7c-455f-8cd5-a4aadd39022e" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FinancingReceivableRevolvingWriteoff"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableYearFiveOriginatedFourYearsBeforeCurrentFiscalYearWriteoff_e1b987a7-9854-4bdd-a41f-814df8f07304" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FinancingReceivableYearFiveOriginatedFourYearsBeforeCurrentFiscalYearWriteoff"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_FinancingReceivableRevolvingWriteoff_e9a8b983-df7c-455f-8cd5-a4aadd39022e" xlink:to="loc_us-gaap_FinancingReceivableYearFiveOriginatedFourYearsBeforeCurrentFiscalYearWriteoff_e1b987a7-9854-4bdd-a41f-814df8f07304" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableOriginatedMoreThanFiveYearsBeforeCurrentFiscalYearWriteoff_ec2f7caf-1158-4a6f-8cb6-7b9e80813b61" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FinancingReceivableOriginatedMoreThanFiveYearsBeforeCurrentFiscalYearWriteoff"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_FinancingReceivableRevolvingWriteoff_e9a8b983-df7c-455f-8cd5-a4aadd39022e" xlink:to="loc_us-gaap_FinancingReceivableOriginatedMoreThanFiveYearsBeforeCurrentFiscalYearWriteoff_ec2f7caf-1158-4a6f-8cb6-7b9e80813b61" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableYearFourOriginatedThreeYearsBeforeCurrentFiscalYearWriteoff_3fe638de-ab1b-49b1-9142-134bdd092eb3" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FinancingReceivableYearFourOriginatedThreeYearsBeforeCurrentFiscalYearWriteoff"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_FinancingReceivableRevolvingWriteoff_e9a8b983-df7c-455f-8cd5-a4aadd39022e" xlink:to="loc_us-gaap_FinancingReceivableYearFourOriginatedThreeYearsBeforeCurrentFiscalYearWriteoff_3fe638de-ab1b-49b1-9142-134bdd092eb3" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableYearOneOriginatedCurrentFiscalYearWriteoff_136c8b4e-cd49-4f9c-92b0-af8df3c4bc46" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FinancingReceivableYearOneOriginatedCurrentFiscalYearWriteoff"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_FinancingReceivableRevolvingWriteoff_e9a8b983-df7c-455f-8cd5-a4aadd39022e" xlink:to="loc_us-gaap_FinancingReceivableYearOneOriginatedCurrentFiscalYearWriteoff_136c8b4e-cd49-4f9c-92b0-af8df3c4bc46" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableYearThreeOriginatedTwoYearsBeforeCurrentFiscalYearWriteoff_1d011b3b-e5fb-4943-8c00-07930d99776c" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FinancingReceivableYearThreeOriginatedTwoYearsBeforeCurrentFiscalYearWriteoff"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_FinancingReceivableRevolvingWriteoff_e9a8b983-df7c-455f-8cd5-a4aadd39022e" xlink:to="loc_us-gaap_FinancingReceivableYearThreeOriginatedTwoYearsBeforeCurrentFiscalYearWriteoff_1d011b3b-e5fb-4943-8c00-07930d99776c" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableYearTwoOriginatedFiscalYearBeforeCurrentFiscalYearWriteoff_1bc8a6cf-bfa2-4021-864d-8359edac3776" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FinancingReceivableYearTwoOriginatedFiscalYearBeforeCurrentFiscalYearWriteoff"/>
    <link:calculationArc order="6" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_FinancingReceivableRevolvingWriteoff_e9a8b983-df7c-455f-8cd5-a4aadd39022e" xlink:to="loc_us-gaap_FinancingReceivableYearTwoOriginatedFiscalYearBeforeCurrentFiscalYearWriteoff_1bc8a6cf-bfa2-4021-864d-8359edac3776" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NotesReceivableGross_47b87a86-12d1-4cdd-8d3a-103933bf1d2c" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_NotesReceivableGross"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableOriginatedTwoYearsBeforeLatestFiscalYear_9119dc99-8032-4c83-b14b-3086043221e6" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FinancingReceivableOriginatedTwoYearsBeforeLatestFiscalYear"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NotesReceivableGross_47b87a86-12d1-4cdd-8d3a-103933bf1d2c" xlink:to="loc_us-gaap_FinancingReceivableOriginatedTwoYearsBeforeLatestFiscalYear_9119dc99-8032-4c83-b14b-3086043221e6" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableOriginatedInCurrentFiscalYear_d445f00d-58b2-4cdf-b948-68e2929feda6" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FinancingReceivableOriginatedInCurrentFiscalYear"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NotesReceivableGross_47b87a86-12d1-4cdd-8d3a-103933bf1d2c" xlink:to="loc_us-gaap_FinancingReceivableOriginatedInCurrentFiscalYear_d445f00d-58b2-4cdf-b948-68e2929feda6" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableOriginatedInFiscalYearBeforeLatestFiscalYear_b5a5bdec-01e7-4e6f-b910-fbc3923e10d2" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FinancingReceivableOriginatedInFiscalYearBeforeLatestFiscalYear"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NotesReceivableGross_47b87a86-12d1-4cdd-8d3a-103933bf1d2c" xlink:to="loc_us-gaap_FinancingReceivableOriginatedInFiscalYearBeforeLatestFiscalYear_b5a5bdec-01e7-4e6f-b910-fbc3923e10d2" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableOriginatedThreeYearsBeforeLatestFiscalYear_aab82a34-dfdf-4bad-8ea1-44ee184ee1b5" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FinancingReceivableOriginatedThreeYearsBeforeLatestFiscalYear"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NotesReceivableGross_47b87a86-12d1-4cdd-8d3a-103933bf1d2c" xlink:to="loc_us-gaap_FinancingReceivableOriginatedThreeYearsBeforeLatestFiscalYear_aab82a34-dfdf-4bad-8ea1-44ee184ee1b5" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableOriginatedFourYearsBeforeLatestFiscalYear_9c6ca7de-6d4b-4ef1-8128-cb41d4c2d782" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FinancingReceivableOriginatedFourYearsBeforeLatestFiscalYear"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NotesReceivableGross_47b87a86-12d1-4cdd-8d3a-103933bf1d2c" xlink:to="loc_us-gaap_FinancingReceivableOriginatedFourYearsBeforeLatestFiscalYear_9c6ca7de-6d4b-4ef1-8128-cb41d4c2d782" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FinancingReceivableOriginatedFiveOrMoreYearsBeforeLatestFiscalYear_44681e00-a501-414e-b592-97b04bbac19d" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FinancingReceivableOriginatedFiveOrMoreYearsBeforeLatestFiscalYear"/>
    <link:calculationArc order="6" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_NotesReceivableGross_47b87a86-12d1-4cdd-8d3a-103933bf1d2c" xlink:to="loc_us-gaap_FinancingReceivableOriginatedFiveOrMoreYearsBeforeLatestFiscalYear_44681e00-a501-414e-b592-97b04bbac19d" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.fanniemae.com/role/DerivativeInstrumentsNotionalandFairValuePositionDetails" xlink:type="simple" xlink:href="fnm-20240930.xsd#DerivativeInstrumentsNotionalandFairValuePositionDetails"/>
  <link:calculationLink xlink:role="http://www.fanniemae.com/role/DerivativeInstrumentsNotionalandFairValuePositionDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeAssets_5c094397-95f5-4735-860a-a6d7d0bd0829" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeAssets"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeAssetFairValueGrossAssetIncludingNotSubjectToMasterNettingArrangement_ea672bd5-89dc-4be1-8874-ac897b03250d" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeAssetFairValueGrossAssetIncludingNotSubjectToMasterNettingArrangement"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeAssets_5c094397-95f5-4735-860a-a6d7d0bd0829" xlink:to="loc_us-gaap_DerivativeAssetFairValueGrossAssetIncludingNotSubjectToMasterNettingArrangement_ea672bd5-89dc-4be1-8874-ac897b03250d" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeAssetFairValueGrossLiability_0002200a-09a4-4f40-9818-cc43dbf3c6f8" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeAssetFairValueGrossLiability"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeAssets_5c094397-95f5-4735-860a-a6d7d0bd0829" xlink:to="loc_us-gaap_DerivativeAssetFairValueGrossLiability_0002200a-09a4-4f40-9818-cc43dbf3c6f8" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeLiabilities_832ba40d-7ef5-487a-9eac-0e3e4f793886" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeLiabilities"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeLiabilityFairValueGrossLiabilityIncludingNotSubjectToMasterNettingArrangement_3465c32d-b2b5-4b0e-b5ec-18ab377deb92" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeLiabilityFairValueGrossLiabilityIncludingNotSubjectToMasterNettingArrangement"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeLiabilities_832ba40d-7ef5-487a-9eac-0e3e4f793886" xlink:to="loc_us-gaap_DerivativeLiabilityFairValueGrossLiabilityIncludingNotSubjectToMasterNettingArrangement_3465c32d-b2b5-4b0e-b5ec-18ab377deb92" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeLiabilityFairValueGrossAsset_d69f69e0-8436-45df-93d8-809fa4428d1d" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeLiabilityFairValueGrossAsset"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeLiabilities_832ba40d-7ef5-487a-9eac-0e3e4f793886" xlink:to="loc_us-gaap_DerivativeLiabilityFairValueGrossAsset_d69f69e0-8436-45df-93d8-809fa4428d1d" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.fanniemae.com/role/DerivativeInstrumentsFVGainsandLossesDetails" xlink:type="simple" xlink:href="fnm-20240930.xsd#DerivativeInstrumentsFVGainsandLossesDetails"/>
  <link:calculationLink xlink:role="http://www.fanniemae.com/role/DerivativeInstrumentsFVGainsandLossesDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_GainLossOnFairValueHedgesRecognizedInEarnings_f26aa475-0df2-45aa-8ecd-7aa1d277cae8" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_GainLossOnFairValueHedgesRecognizedInEarnings"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ChangeInUnrealizedGainLossOnHedgedItemInFairValueHedge1_fd51571c-9c2c-4e9d-aa1a-57789c53b616" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_ChangeInUnrealizedGainLossOnHedgedItemInFairValueHedge1"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_GainLossOnFairValueHedgesRecognizedInEarnings_f26aa475-0df2-45aa-8ecd-7aa1d277cae8" xlink:to="loc_us-gaap_ChangeInUnrealizedGainLossOnHedgedItemInFairValueHedge1_fd51571c-9c2c-4e9d-aa1a-57789c53b616" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ChangeInUnrealizedGainLossOnFairValueHedgingInstruments1_c22e5fda-fbb0-4154-90ca-5574a9b570ba" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_ChangeInUnrealizedGainLossOnFairValueHedgingInstruments1"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_GainLossOnFairValueHedgesRecognizedInEarnings_f26aa475-0df2-45aa-8ecd-7aa1d277cae8" xlink:to="loc_us-gaap_ChangeInUnrealizedGainLossOnFairValueHedgingInstruments1_c22e5fda-fbb0-4154-90ca-5574a9b570ba" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_fnm_InterestAccrualsOnHedgingInstruments_adf129a2-0107-4fd5-b6bb-fb9b3cb72fbc" xlink:href="fnm-20240930.xsd#fnm_InterestAccrualsOnHedgingInstruments"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_GainLossOnFairValueHedgesRecognizedInEarnings_f26aa475-0df2-45aa-8ecd-7aa1d277cae8" xlink:to="loc_fnm_InterestAccrualsOnHedgingInstruments_adf129a2-0107-4fd5-b6bb-fb9b3cb72fbc" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_fnm_DiscontinuedHedgeRelatedBasisAdjustmentAmortization_f71005cc-cee2-456b-a629-69bb35656cbd" xlink:href="fnm-20240930.xsd#fnm_DiscontinuedHedgeRelatedBasisAdjustmentAmortization"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_GainLossOnFairValueHedgesRecognizedInEarnings_f26aa475-0df2-45aa-8ecd-7aa1d277cae8" xlink:to="loc_fnm_DiscontinuedHedgeRelatedBasisAdjustmentAmortization_f71005cc-cee2-456b-a629-69bb35656cbd" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.fanniemae.com/role/SegmentReportingDetails" xlink:type="simple" xlink:href="fnm-20240930.xsd#SegmentReportingDetails"/>
  <link:calculationLink xlink:role="http://www.fanniemae.com/role/SegmentReportingDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_97cbb7c5-bb7f-443c-82a7-bb926dc2e840" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_RevenuesNetOfInterestExpense_ba7c8afd-827c-4a50-82ba-436ee2c1028c" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_RevenuesNetOfInterestExpense"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_97cbb7c5-bb7f-443c-82a7-bb926dc2e840" xlink:to="loc_us-gaap_RevenuesNetOfInterestExpense_ba7c8afd-827c-4a50-82ba-436ee2c1028c" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_GainLossOnInvestments_97888b29-273e-4be3-8801-51239b38dea9" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_GainLossOnInvestments"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_97cbb7c5-bb7f-443c-82a7-bb926dc2e840" xlink:to="loc_us-gaap_GainLossOnInvestments_97888b29-273e-4be3-8801-51239b38dea9" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ProvisionForLoanLeaseAndOtherLosses_b1d2d7d6-ed20-475a-b4da-263102ff2c9d" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_ProvisionForLoanLeaseAndOtherLosses"/>
    <link:calculationArc order="3" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_97cbb7c5-bb7f-443c-82a7-bb926dc2e840" xlink:to="loc_us-gaap_ProvisionForLoanLeaseAndOtherLosses_b1d2d7d6-ed20-475a-b4da-263102ff2c9d" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_OtherNoninterestExpense_7a8ce11f-b8b2-425d-9769-a776f483bcc8" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_OtherNoninterestExpense"/>
    <link:calculationArc order="4" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_97cbb7c5-bb7f-443c-82a7-bb926dc2e840" xlink:to="loc_us-gaap_OtherNoninterestExpense_7a8ce11f-b8b2-425d-9769-a776f483bcc8" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_fnm_ChangeInExpectedCreditEnhancementRecoveries_923c23df-406e-48a0-9b9a-9a85584a7c34" xlink:href="fnm-20240930.xsd#fnm_ChangeInExpectedCreditEnhancementRecoveries"/>
    <link:calculationArc order="5" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_97cbb7c5-bb7f-443c-82a7-bb926dc2e840" xlink:to="loc_fnm_ChangeInExpectedCreditEnhancementRecoveries_923c23df-406e-48a0-9b9a-9a85584a7c34" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FairValueOptionChangesInFairValueGainLoss1_4721691d-db3b-47ed-92ab-95c79b891d18" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FairValueOptionChangesInFairValueGainLoss1"/>
    <link:calculationArc order="6" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_97cbb7c5-bb7f-443c-82a7-bb926dc2e840" xlink:to="loc_us-gaap_FairValueOptionChangesInFairValueGainLoss1_4721691d-db3b-47ed-92ab-95c79b891d18" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_fnm_SingleFamilyGuarantyFeeTemporaryPayrollTaxCutContinuationActOf2011_e798c528-ba0c-4b76-8c7b-2f179d406352" xlink:href="fnm-20240930.xsd#fnm_SingleFamilyGuarantyFeeTemporaryPayrollTaxCutContinuationActOf2011"/>
    <link:calculationArc order="7" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_97cbb7c5-bb7f-443c-82a7-bb926dc2e840" xlink:to="loc_fnm_SingleFamilyGuarantyFeeTemporaryPayrollTaxCutContinuationActOf2011_e798c528-ba0c-4b76-8c7b-2f179d406352" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_fnm_CreditEnhancementExpense_3586436b-8f00-4ca7-add1-35ef784e48ad" xlink:href="fnm-20240930.xsd#fnm_CreditEnhancementExpense"/>
    <link:calculationArc order="8" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_97cbb7c5-bb7f-443c-82a7-bb926dc2e840" xlink:to="loc_fnm_CreditEnhancementExpense_3586436b-8f00-4ca7-add1-35ef784e48ad" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_GeneralAndAdministrativeExpense_33216da0-e066-4580-8aa3-fa65b212ef4f" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_GeneralAndAdministrativeExpense"/>
    <link:calculationArc order="9" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_97cbb7c5-bb7f-443c-82a7-bb926dc2e840" xlink:to="loc_us-gaap_GeneralAndAdministrativeExpense_33216da0-e066-4580-8aa3-fa65b212ef4f" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ProfitLoss_800b1df4-3ac8-4b2a-b2df-1b04b77b41d5" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_ProfitLoss"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncomeTaxExpenseBenefit_ad50a41c-5ea9-42ed-b1d7-77f4e1870803" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_IncomeTaxExpenseBenefit"/>
    <link:calculationArc order="1" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_ProfitLoss_800b1df4-3ac8-4b2a-b2df-1b04b77b41d5" xlink:to="loc_us-gaap_IncomeTaxExpenseBenefit_ad50a41c-5ea9-42ed-b1d7-77f4e1870803" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_db032daf-354b-4a92-acf7-52c63692b578" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_ProfitLoss_800b1df4-3ac8-4b2a-b2df-1b04b77b41d5" xlink:to="loc_us-gaap_IncomeLossFromContinuingOperationsBeforeIncomeTaxesExtraordinaryItemsNoncontrollingInterest_db032daf-354b-4a92-acf7-52c63692b578" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_RevenuesNetOfInterestExpense_fee874b2-7e94-4d8d-9f82-5de21234ad39" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_RevenuesNetOfInterestExpense"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_NoninterestIncomeOther_50c8f1e8-ddc0-46e6-9ba4-5dcc47e15462" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_NoninterestIncomeOther"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_RevenuesNetOfInterestExpense_fee874b2-7e94-4d8d-9f82-5de21234ad39" xlink:to="loc_us-gaap_NoninterestIncomeOther_50c8f1e8-ddc0-46e6-9ba4-5dcc47e15462" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_InterestIncomeExpenseNet_dc8a0c85-bd4f-4dc8-9b76-08464a4e77af" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_InterestIncomeExpenseNet"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_RevenuesNetOfInterestExpense_fee874b2-7e94-4d8d-9f82-5de21234ad39" xlink:to="loc_us-gaap_InterestIncomeExpenseNet_dc8a0c85-bd4f-4dc8-9b76-08464a4e77af" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.fanniemae.com/role/NettingArrangementsDetails" xlink:type="simple" xlink:href="fnm-20240930.xsd#NettingArrangementsDetails"/>
  <link:calculationLink xlink:role="http://www.fanniemae.com/role/NettingArrangementsDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeAssetSecurityPurchasedUnderAgreementToResellSecurityBorrowedAfterOffsetSubjectToMasterNettingArrangement_c111523c-bf23-4df5-b485-0ea8bb023352" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeAssetSecurityPurchasedUnderAgreementToResellSecurityBorrowedAfterOffsetSubjectToMasterNettingArrangement"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeAssetSecuritiesPurchasedUnderAgreementsToResellSecuritiesBorrowedGross_7180bb78-f59b-4146-b7cd-b9de170f6015" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeAssetSecuritiesPurchasedUnderAgreementsToResellSecuritiesBorrowedGross"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeAssetSecurityPurchasedUnderAgreementToResellSecurityBorrowedAfterOffsetSubjectToMasterNettingArrangement_c111523c-bf23-4df5-b485-0ea8bb023352" xlink:to="loc_us-gaap_DerivativeAssetSecuritiesPurchasedUnderAgreementsToResellSecuritiesBorrowedGross_7180bb78-f59b-4146-b7cd-b9de170f6015" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeAssetSecuritiesPurchasedUnderAgreementsToResellSecuritiesBorrowedLiability_30f0ad8a-e00d-4955-bc4b-0799c05b4c0d" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeAssetSecuritiesPurchasedUnderAgreementsToResellSecuritiesBorrowedLiability"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeAssetSecurityPurchasedUnderAgreementToResellSecurityBorrowedAfterOffsetSubjectToMasterNettingArrangement_c111523c-bf23-4df5-b485-0ea8bb023352" xlink:to="loc_us-gaap_DerivativeAssetSecuritiesPurchasedUnderAgreementsToResellSecuritiesBorrowedLiability_30f0ad8a-e00d-4955-bc4b-0799c05b4c0d" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeAssetSecuritiesPurchasedUnderAgreementsToResellSecuritiesBorrowedNotOffsetPolicyElectionDeduction_a0e017cc-4bb6-4e47-9a23-97d3d67661b0" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeAssetSecuritiesPurchasedUnderAgreementsToResellSecuritiesBorrowedNotOffsetPolicyElectionDeduction"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeAssetNotOffsetPolicyElectionDeduction_21298eee-e4ed-404d-8bdf-3d13b875565c" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeAssetNotOffsetPolicyElectionDeduction"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeAssetSecuritiesPurchasedUnderAgreementsToResellSecuritiesBorrowedNotOffsetPolicyElectionDeduction_a0e017cc-4bb6-4e47-9a23-97d3d67661b0" xlink:to="loc_us-gaap_DerivativeAssetNotOffsetPolicyElectionDeduction_21298eee-e4ed-404d-8bdf-3d13b875565c" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_SecuritiesPurchasedUnderAgreementsToResellNotOffsetPolicyElectionDeduction_0d0c465e-0527-4e66-a9c8-8abb2411b286" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_SecuritiesPurchasedUnderAgreementsToResellNotOffsetPolicyElectionDeduction"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeAssetSecuritiesPurchasedUnderAgreementsToResellSecuritiesBorrowedNotOffsetPolicyElectionDeduction_a0e017cc-4bb6-4e47-9a23-97d3d67661b0" xlink:to="loc_us-gaap_SecuritiesPurchasedUnderAgreementsToResellNotOffsetPolicyElectionDeduction_0d0c465e-0527-4e66-a9c8-8abb2411b286" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeLiabilitySecuritiesSoldUnderAgreementsToResellSecuritiesLoanedGross_4d5f425f-28bc-4e61-b872-58bce0374568" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeLiabilitySecuritiesSoldUnderAgreementsToResellSecuritiesLoanedGross"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeFairValueOfDerivativeLiability_ca48af61-214b-43d2-833b-435aacc3c8ce" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeFairValueOfDerivativeLiability"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeLiabilitySecuritiesSoldUnderAgreementsToResellSecuritiesLoanedGross_4d5f425f-28bc-4e61-b872-58bce0374568" xlink:to="loc_us-gaap_DerivativeFairValueOfDerivativeLiability_ca48af61-214b-43d2-833b-435aacc3c8ce" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeLiabilitySecuritySoldUnderAgreementToRepurchaseSecurityLoanedAfterOffsetSubjectToMasterNettingArrangement_d57d2812-aea3-4eb6-b495-9bf14b909f67" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeLiabilitySecuritySoldUnderAgreementToRepurchaseSecurityLoanedAfterOffsetSubjectToMasterNettingArrangement"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeFairValueOfDerivativeLiabilityAmountNotOffsetAgainstCollateral_17bff9b0-6876-4955-a4b4-446cc5caab20" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeFairValueOfDerivativeLiabilityAmountNotOffsetAgainstCollateral"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeLiabilitySecuritySoldUnderAgreementToRepurchaseSecurityLoanedAfterOffsetSubjectToMasterNettingArrangement_d57d2812-aea3-4eb6-b495-9bf14b909f67" xlink:to="loc_us-gaap_DerivativeFairValueOfDerivativeLiabilityAmountNotOffsetAgainstCollateral_17bff9b0-6876-4955-a4b4-446cc5caab20" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeFairValueOfDerivativeLiabilityAmountNotOffsetAgainstCollateral_6d6d9495-a5a4-4c0e-886a-4159c7c33041" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeFairValueOfDerivativeLiabilityAmountNotOffsetAgainstCollateral"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeFairValueOfDerivativeLiability_9244b65b-f4e9-48b3-970c-e0e21d298528" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeFairValueOfDerivativeLiability"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeFairValueOfDerivativeLiabilityAmountNotOffsetAgainstCollateral_6d6d9495-a5a4-4c0e-886a-4159c7c33041" xlink:to="loc_us-gaap_DerivativeFairValueOfDerivativeLiability_9244b65b-f4e9-48b3-970c-e0e21d298528" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeLiabilityFairValueGrossAsset_0d58a092-6832-49cc-a01e-25eea3ad27be" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeLiabilityFairValueGrossAsset"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeFairValueOfDerivativeLiabilityAmountNotOffsetAgainstCollateral_6d6d9495-a5a4-4c0e-886a-4159c7c33041" xlink:to="loc_us-gaap_DerivativeLiabilityFairValueGrossAsset_0d58a092-6832-49cc-a01e-25eea3ad27be" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeFairValueOfDerivativeAssetAmountNotOffsetAgainstCollateral_84d60db9-0cfb-4a39-ad2e-a415dfa10226" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeFairValueOfDerivativeAssetAmountNotOffsetAgainstCollateral"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeAssetFairValueGrossLiability_5d59ee4f-008c-4ffe-9f76-bd3d973ad252" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeAssetFairValueGrossLiability"/>
    <link:calculationArc order="1" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeFairValueOfDerivativeAssetAmountNotOffsetAgainstCollateral_84d60db9-0cfb-4a39-ad2e-a415dfa10226" xlink:to="loc_us-gaap_DerivativeAssetFairValueGrossLiability_5d59ee4f-008c-4ffe-9f76-bd3d973ad252" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeFairValueOfDerivativeAsset_a200202d-287b-456a-8549-a789ca718516" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeFairValueOfDerivativeAsset"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeFairValueOfDerivativeAssetAmountNotOffsetAgainstCollateral_84d60db9-0cfb-4a39-ad2e-a415dfa10226" xlink:to="loc_us-gaap_DerivativeFairValueOfDerivativeAsset_a200202d-287b-456a-8549-a789ca718516" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeLiabilitySecuritiesSoldUnderAgreementsToResellSecuritiesLoanedAsset_8f25c020-b794-4da9-a739-725837ef1d09" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeLiabilitySecuritiesSoldUnderAgreementsToResellSecuritiesLoanedAsset"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeLiabilityFairValueGrossAsset_75e8824b-5ce6-4bec-9a3d-03ed09fc0a1a" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeLiabilityFairValueGrossAsset"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeLiabilitySecuritiesSoldUnderAgreementsToResellSecuritiesLoanedAsset_8f25c020-b794-4da9-a739-725837ef1d09" xlink:to="loc_us-gaap_DerivativeLiabilityFairValueGrossAsset_75e8824b-5ce6-4bec-9a3d-03ed09fc0a1a" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeLiabilitySecuritiesSoldUnderAgreementsToResellSecuritiesLoanedNotOffsetPolicyElectionDeduction_32c4e28b-f880-40b1-9f9d-df6e26dcbe68" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeLiabilitySecuritiesSoldUnderAgreementsToResellSecuritiesLoanedNotOffsetPolicyElectionDeduction"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeLiabilityNotOffsetPolicyElectionDeduction_b4223127-c0d4-4d38-8c14-5f9bf6fbd836" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeLiabilityNotOffsetPolicyElectionDeduction"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeLiabilitySecuritiesSoldUnderAgreementsToResellSecuritiesLoanedNotOffsetPolicyElectionDeduction_32c4e28b-f880-40b1-9f9d-df6e26dcbe68" xlink:to="loc_us-gaap_DerivativeLiabilityNotOffsetPolicyElectionDeduction_b4223127-c0d4-4d38-8c14-5f9bf6fbd836" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeFairValueOfDerivativeAssetAmountOffsetAgainstCollateral_5274e671-40f1-4684-b3aa-00e532058e80" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeFairValueOfDerivativeAssetAmountOffsetAgainstCollateral"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeFairValueOfDerivativeAssetAmountNotOffsetAgainstCollateral_9c465347-9416-4a3b-9f88-b928b60ff255" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeFairValueOfDerivativeAssetAmountNotOffsetAgainstCollateral"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeFairValueOfDerivativeAssetAmountOffsetAgainstCollateral_5274e671-40f1-4684-b3aa-00e532058e80" xlink:to="loc_us-gaap_DerivativeFairValueOfDerivativeAssetAmountNotOffsetAgainstCollateral_9c465347-9416-4a3b-9f88-b928b60ff255" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeAssetNotOffsetPolicyElectionDeduction_cfa04cec-b6e3-4201-bc45-99eb3f8533af" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeAssetNotOffsetPolicyElectionDeduction"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeFairValueOfDerivativeAssetAmountOffsetAgainstCollateral_5274e671-40f1-4684-b3aa-00e532058e80" xlink:to="loc_us-gaap_DerivativeAssetNotOffsetPolicyElectionDeduction_cfa04cec-b6e3-4201-bc45-99eb3f8533af" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeCollateralObligationToReturnSecurities_66ac62fb-8814-4c77-bc8d-0342355e90a9" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeCollateralObligationToReturnSecurities"/>
    <link:calculationArc order="3" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeFairValueOfDerivativeAssetAmountOffsetAgainstCollateral_5274e671-40f1-4684-b3aa-00e532058e80" xlink:to="loc_us-gaap_DerivativeCollateralObligationToReturnSecurities_66ac62fb-8814-4c77-bc8d-0342355e90a9" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeAssetSecuritiesPurchasedUnderAgreementsToResellSecuritiesBorrowedGross_3e81c920-31ef-46da-bd51-e60b053913d3" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeAssetSecuritiesPurchasedUnderAgreementsToResellSecuritiesBorrowedGross"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeFairValueOfDerivativeAsset_1be4a71c-d569-470b-8a81-18e8e86c0b6c" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeFairValueOfDerivativeAsset"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeAssetSecuritiesPurchasedUnderAgreementsToResellSecuritiesBorrowedGross_3e81c920-31ef-46da-bd51-e60b053913d3" xlink:to="loc_us-gaap_DerivativeFairValueOfDerivativeAsset_1be4a71c-d569-470b-8a81-18e8e86c0b6c" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_SecuritiesPurchasedUnderAgreementsToResellGross_1deb5941-65e4-457b-aa92-b1124a4063cf" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_SecuritiesPurchasedUnderAgreementsToResellGross"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeAssetSecuritiesPurchasedUnderAgreementsToResellSecuritiesBorrowedGross_3e81c920-31ef-46da-bd51-e60b053913d3" xlink:to="loc_us-gaap_SecuritiesPurchasedUnderAgreementsToResellGross_1deb5941-65e4-457b-aa92-b1124a4063cf" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeLiabilitySecuritiesSoldUnderAgreementsToResellSecuritiesLoanedAmountOffsetAgainstCollateral_6f8dd210-f032-4240-bdb6-3227bae07b4f" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeLiabilitySecuritiesSoldUnderAgreementsToResellSecuritiesLoanedAmountOffsetAgainstCollateral"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeLiabilitySecuritySoldUnderAgreementToRepurchaseSecurityLoanedAfterOffsetSubjectToMasterNettingArrangement_d0238384-7b65-4693-bf8d-f318f3a87f28" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeLiabilitySecuritySoldUnderAgreementToRepurchaseSecurityLoanedAfterOffsetSubjectToMasterNettingArrangement"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeLiabilitySecuritiesSoldUnderAgreementsToResellSecuritiesLoanedAmountOffsetAgainstCollateral_6f8dd210-f032-4240-bdb6-3227bae07b4f" xlink:to="loc_us-gaap_DerivativeLiabilitySecuritySoldUnderAgreementToRepurchaseSecurityLoanedAfterOffsetSubjectToMasterNettingArrangement_d0238384-7b65-4693-bf8d-f318f3a87f28" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeLiabilitySecuritiesSoldUnderAgreementsToResellSecuritiesLoanedNotOffsetPolicyElectionDeduction_d9b35d5b-ad74-427e-bb24-a912525de662" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeLiabilitySecuritiesSoldUnderAgreementsToResellSecuritiesLoanedNotOffsetPolicyElectionDeduction"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeLiabilitySecuritiesSoldUnderAgreementsToResellSecuritiesLoanedAmountOffsetAgainstCollateral_6f8dd210-f032-4240-bdb6-3227bae07b4f" xlink:to="loc_us-gaap_DerivativeLiabilitySecuritiesSoldUnderAgreementsToResellSecuritiesLoanedNotOffsetPolicyElectionDeduction_d9b35d5b-ad74-427e-bb24-a912525de662" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeLiabilitySecuritiesSoldUnderAgreementsToResellSecuritiesLoanedCollateralRightToReclaimSecurities_21460b69-c23e-410a-bc25-f317afb8c1a6" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeLiabilitySecuritiesSoldUnderAgreementsToResellSecuritiesLoanedCollateralRightToReclaimSecurities"/>
    <link:calculationArc order="3" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeLiabilitySecuritiesSoldUnderAgreementsToResellSecuritiesLoanedAmountOffsetAgainstCollateral_6f8dd210-f032-4240-bdb6-3227bae07b4f" xlink:to="loc_us-gaap_DerivativeLiabilitySecuritiesSoldUnderAgreementsToResellSecuritiesLoanedCollateralRightToReclaimSecurities_21460b69-c23e-410a-bc25-f317afb8c1a6" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_SecuritiesPurchasedUnderAgreementsToResellAmountOffsetAgainstCollateral_e1e8ecff-1cfe-43c8-9e21-2115ee8bd397" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_SecuritiesPurchasedUnderAgreementsToResellAmountOffsetAgainstCollateral"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_SecuritiesPurchasedUnderAgreementsToResellNotOffsetPolicyElectionDeduction_11b3a11e-fea3-4bdf-b767-72bb8fe24f17" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_SecuritiesPurchasedUnderAgreementsToResellNotOffsetPolicyElectionDeduction"/>
    <link:calculationArc order="1" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_SecuritiesPurchasedUnderAgreementsToResellAmountOffsetAgainstCollateral_e1e8ecff-1cfe-43c8-9e21-2115ee8bd397" xlink:to="loc_us-gaap_SecuritiesPurchasedUnderAgreementsToResellNotOffsetPolicyElectionDeduction_11b3a11e-fea3-4bdf-b767-72bb8fe24f17" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_SecuritiesPurchasedUnderAgreementsToResellCollateralObligationToReturnSecurities_20cebe0b-0721-493a-8221-e8abb1bd0326" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_SecuritiesPurchasedUnderAgreementsToResellCollateralObligationToReturnSecurities"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_SecuritiesPurchasedUnderAgreementsToResellAmountOffsetAgainstCollateral_e1e8ecff-1cfe-43c8-9e21-2115ee8bd397" xlink:to="loc_us-gaap_SecuritiesPurchasedUnderAgreementsToResellCollateralObligationToReturnSecurities_20cebe0b-0721-493a-8221-e8abb1bd0326" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_SecuritiesPurchasedUnderAgreementsToResellNotSubjectToMasterNettingArrangement_218fbc03-b6b9-4355-a83c-1e4d91637f9b" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_SecuritiesPurchasedUnderAgreementsToResellNotSubjectToMasterNettingArrangement"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_SecuritiesPurchasedUnderAgreementsToResellAmountOffsetAgainstCollateral_e1e8ecff-1cfe-43c8-9e21-2115ee8bd397" xlink:to="loc_us-gaap_SecuritiesPurchasedUnderAgreementsToResellNotSubjectToMasterNettingArrangement_218fbc03-b6b9-4355-a83c-1e4d91637f9b" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeAssetSecuritiesPurchasedUnderAgreementsToResellSecuritiesBorrowedLiability_0c957d8a-72e6-4860-9d73-ebcc0b9755a8" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeAssetSecuritiesPurchasedUnderAgreementsToResellSecuritiesBorrowedLiability"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeAssetFairValueGrossLiability_f1e02a10-f6bc-44a3-b87a-31f146ad4af9" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeAssetFairValueGrossLiability"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeAssetSecuritiesPurchasedUnderAgreementsToResellSecuritiesBorrowedLiability_0c957d8a-72e6-4860-9d73-ebcc0b9755a8" xlink:to="loc_us-gaap_DerivativeAssetFairValueGrossLiability_f1e02a10-f6bc-44a3-b87a-31f146ad4af9" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_SecuritiesPurchasedUnderAgreementsToResellLiability_6bfc7fff-864a-4aa3-9510-6a18807f5d0c" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_SecuritiesPurchasedUnderAgreementsToResellLiability"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeAssetSecuritiesPurchasedUnderAgreementsToResellSecuritiesBorrowedLiability_0c957d8a-72e6-4860-9d73-ebcc0b9755a8" xlink:to="loc_us-gaap_SecuritiesPurchasedUnderAgreementsToResellLiability_6bfc7fff-864a-4aa3-9510-6a18807f5d0c" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeAssetSecuritiesPurchasedUnderAgreementsToResellSecuritiesBorrowedAmountOffsetAgainstCollateral_6a54e11e-e16b-4466-b089-0d6ba10c554b" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeAssetSecuritiesPurchasedUnderAgreementsToResellSecuritiesBorrowedAmountOffsetAgainstCollateral"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeFairValueOfDerivativeAssetAmountOffsetAgainstCollateral_026aa3b4-a3e8-47ed-bd7b-ff9d311b4d86" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeFairValueOfDerivativeAssetAmountOffsetAgainstCollateral"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeAssetSecuritiesPurchasedUnderAgreementsToResellSecuritiesBorrowedAmountOffsetAgainstCollateral_6a54e11e-e16b-4466-b089-0d6ba10c554b" xlink:to="loc_us-gaap_DerivativeFairValueOfDerivativeAssetAmountOffsetAgainstCollateral_026aa3b4-a3e8-47ed-bd7b-ff9d311b4d86" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_SecuritiesPurchasedUnderAgreementsToResellAmountOffsetAgainstCollateral_f5793b14-ccf3-4253-a257-dfa7c5fd5dce" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_SecuritiesPurchasedUnderAgreementsToResellAmountOffsetAgainstCollateral"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeAssetSecuritiesPurchasedUnderAgreementsToResellSecuritiesBorrowedAmountOffsetAgainstCollateral_6a54e11e-e16b-4466-b089-0d6ba10c554b" xlink:to="loc_us-gaap_SecuritiesPurchasedUnderAgreementsToResellAmountOffsetAgainstCollateral_f5793b14-ccf3-4253-a257-dfa7c5fd5dce" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeFairValueOfDerivativeLiabilityAmountOffsetAgainstCollateral_fb4f5ec3-ca20-4653-949f-57bc5c7df81d" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeFairValueOfDerivativeLiabilityAmountOffsetAgainstCollateral"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeCollateralRightToReclaimSecurities_1e4f6249-314b-4920-a202-a9e51b56ffd7" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeCollateralRightToReclaimSecurities"/>
    <link:calculationArc order="1" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeFairValueOfDerivativeLiabilityAmountOffsetAgainstCollateral_fb4f5ec3-ca20-4653-949f-57bc5c7df81d" xlink:to="loc_us-gaap_DerivativeCollateralRightToReclaimSecurities_1e4f6249-314b-4920-a202-a9e51b56ffd7" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeFairValueOfDerivativeLiabilityAmountNotOffsetAgainstCollateral_0beae803-35b0-4ed1-a683-f9aff2e8e5c3" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeFairValueOfDerivativeLiabilityAmountNotOffsetAgainstCollateral"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeFairValueOfDerivativeLiabilityAmountOffsetAgainstCollateral_fb4f5ec3-ca20-4653-949f-57bc5c7df81d" xlink:to="loc_us-gaap_DerivativeFairValueOfDerivativeLiabilityAmountNotOffsetAgainstCollateral_0beae803-35b0-4ed1-a683-f9aff2e8e5c3" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeLiabilityNotOffsetPolicyElectionDeduction_1c6477cb-7898-4368-9639-984cd1a8b990" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeLiabilityNotOffsetPolicyElectionDeduction"/>
    <link:calculationArc order="3" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeFairValueOfDerivativeLiabilityAmountOffsetAgainstCollateral_fb4f5ec3-ca20-4653-949f-57bc5c7df81d" xlink:to="loc_us-gaap_DerivativeLiabilityNotOffsetPolicyElectionDeduction_1c6477cb-7898-4368-9639-984cd1a8b990" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeAssetSecuritiesPurchasedUnderAgreementsToResellSecuritiesBorrowedCollateralObligationToReturnSecurities_3c912c50-5efe-4c1b-9664-947ddc3f3fa6" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeAssetSecuritiesPurchasedUnderAgreementsToResellSecuritiesBorrowedCollateralObligationToReturnSecurities"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeCollateralObligationToReturnSecurities_3cf851d2-fe40-43a1-bd06-e2055c2a44a8" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeCollateralObligationToReturnSecurities"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeAssetSecuritiesPurchasedUnderAgreementsToResellSecuritiesBorrowedCollateralObligationToReturnSecurities_3c912c50-5efe-4c1b-9664-947ddc3f3fa6" xlink:to="loc_us-gaap_DerivativeCollateralObligationToReturnSecurities_3cf851d2-fe40-43a1-bd06-e2055c2a44a8" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_SecuritiesPurchasedUnderAgreementsToResellCollateralObligationToReturnSecurities_a57f675d-e32e-44ef-808e-280feedcea7e" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_SecuritiesPurchasedUnderAgreementsToResellCollateralObligationToReturnSecurities"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeAssetSecuritiesPurchasedUnderAgreementsToResellSecuritiesBorrowedCollateralObligationToReturnSecurities_3c912c50-5efe-4c1b-9664-947ddc3f3fa6" xlink:to="loc_us-gaap_SecuritiesPurchasedUnderAgreementsToResellCollateralObligationToReturnSecurities_a57f675d-e32e-44ef-808e-280feedcea7e" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeLiabilitySecuritiesSoldUnderAgreementsToResellSecuritiesLoanedCollateralRightToReclaimSecurities_807f281c-2172-492a-a735-16727cf62937" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeLiabilitySecuritiesSoldUnderAgreementsToResellSecuritiesLoanedCollateralRightToReclaimSecurities"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeCollateralRightToReclaimSecurities_71477d90-14d8-45b5-a3b5-d7100a87f80d" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeCollateralRightToReclaimSecurities"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeLiabilitySecuritiesSoldUnderAgreementsToResellSecuritiesLoanedCollateralRightToReclaimSecurities_807f281c-2172-492a-a735-16727cf62937" xlink:to="loc_us-gaap_DerivativeCollateralRightToReclaimSecurities_71477d90-14d8-45b5-a3b5-d7100a87f80d" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.fanniemae.com/role/NettingArrangementsDetails_1" xlink:type="simple" xlink:href="fnm-20240930.xsd#NettingArrangementsDetails_1"/>
  <link:calculationLink xlink:role="http://www.fanniemae.com/role/NettingArrangementsDetails_1" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeLiabilitySecuritySoldUnderAgreementToRepurchaseSecurityLoanedAfterOffsetSubjectToMasterNettingArrangement_69cc50a4-ea3b-4e0e-9a3d-9e52aa259fd5" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeLiabilitySecuritySoldUnderAgreementToRepurchaseSecurityLoanedAfterOffsetSubjectToMasterNettingArrangement"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeLiabilitySecuritiesSoldUnderAgreementsToResellSecuritiesLoanedGross_c5661189-6bd6-4fd0-9e8c-2cdeb44d9df5" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeLiabilitySecuritiesSoldUnderAgreementsToResellSecuritiesLoanedGross"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeLiabilitySecuritySoldUnderAgreementToRepurchaseSecurityLoanedAfterOffsetSubjectToMasterNettingArrangement_69cc50a4-ea3b-4e0e-9a3d-9e52aa259fd5" xlink:to="loc_us-gaap_DerivativeLiabilitySecuritiesSoldUnderAgreementsToResellSecuritiesLoanedGross_c5661189-6bd6-4fd0-9e8c-2cdeb44d9df5" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeLiabilitySecuritiesSoldUnderAgreementsToResellSecuritiesLoanedAsset_92088891-1b67-4248-a903-4166fb377868" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeLiabilitySecuritiesSoldUnderAgreementsToResellSecuritiesLoanedAsset"/>
    <link:calculationArc order="2" weight="-1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeLiabilitySecuritySoldUnderAgreementToRepurchaseSecurityLoanedAfterOffsetSubjectToMasterNettingArrangement_69cc50a4-ea3b-4e0e-9a3d-9e52aa259fd5" xlink:to="loc_us-gaap_DerivativeLiabilitySecuritiesSoldUnderAgreementsToResellSecuritiesLoanedAsset_92088891-1b67-4248-a903-4166fb377868" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeLiabilitySecuritiesSoldUnderAgreementsToResellSecuritiesLoanedAmountOffsetAgainstCollateral_4e0ddc12-94e4-40da-9681-0c077b0f2a21" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeLiabilitySecuritiesSoldUnderAgreementsToResellSecuritiesLoanedAmountOffsetAgainstCollateral"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeFairValueOfDerivativeLiabilityAmountOffsetAgainstCollateral_19dc7afa-e40b-4211-8409-c610a2c8f3d1" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeFairValueOfDerivativeLiabilityAmountOffsetAgainstCollateral"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_DerivativeLiabilitySecuritiesSoldUnderAgreementsToResellSecuritiesLoanedAmountOffsetAgainstCollateral_4e0ddc12-94e4-40da-9681-0c077b0f2a21" xlink:to="loc_us-gaap_DerivativeFairValueOfDerivativeLiabilityAmountOffsetAgainstCollateral_19dc7afa-e40b-4211-8409-c610a2c8f3d1" xlink:type="arc"/>
  </link:calculationLink>
  <link:roleRef roleURI="http://www.fanniemae.com/role/FairValueFairValueofFinancialInstrumentsDetails" xlink:type="simple" xlink:href="fnm-20240930.xsd#FairValueFairValueofFinancialInstrumentsDetails"/>
  <link:calculationLink xlink:role="http://www.fanniemae.com/role/FairValueFairValueofFinancialInstrumentsDetails" xlink:type="extended">
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AssetsFairValueDisclosure_8262566d-49ad-4f56-aa6d-6d4f57353462" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_AssetsFairValueDisclosure"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_MortgagesHeldForSaleFairValueDisclosure_ee8e223d-3362-416a-ac08-6c1bb3c4a0dd" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_MortgagesHeldForSaleFairValueDisclosure"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AssetsFairValueDisclosure_8262566d-49ad-4f56-aa6d-6d4f57353462" xlink:to="loc_us-gaap_MortgagesHeldForSaleFairValueDisclosure_ee8e223d-3362-416a-ac08-6c1bb3c4a0dd" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_AdvancesFairValueDisclosure_36bdca56-ddde-466e-aa32-c019c17c1e18" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_AdvancesFairValueDisclosure"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AssetsFairValueDisclosure_8262566d-49ad-4f56-aa6d-6d4f57353462" xlink:to="loc_us-gaap_AdvancesFairValueDisclosure_36bdca56-ddde-466e-aa32-c019c17c1e18" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_FederalFundsSoldAndSecuritiesBorrowedOrPurchasedUnderAgreementsToResellFairValueDisclosure_0be4ecad-a70f-4b2d-a39f-2090fc34d741" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_FederalFundsSoldAndSecuritiesBorrowedOrPurchasedUnderAgreementsToResellFairValueDisclosure"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AssetsFairValueDisclosure_8262566d-49ad-4f56-aa6d-6d4f57353462" xlink:to="loc_us-gaap_FederalFundsSoldAndSecuritiesBorrowedOrPurchasedUnderAgreementsToResellFairValueDisclosure_0be4ecad-a70f-4b2d-a39f-2090fc34d741" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_fnm_GuarantyAssetsAndBuyUpsFairValueDisclosure_9be43ea4-fcfa-4c24-968b-19b4195e0e57" xlink:href="fnm-20240930.xsd#fnm_GuarantyAssetsAndBuyUpsFairValueDisclosure"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AssetsFairValueDisclosure_8262566d-49ad-4f56-aa6d-6d4f57353462" xlink:to="loc_fnm_GuarantyAssetsAndBuyUpsFairValueDisclosure_9be43ea4-fcfa-4c24-968b-19b4195e0e57" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_fnm_CashCashEquivalentsAndRestrictedCashFairValueDisclosure_1e88f155-677b-486d-a187-62200eebf075" xlink:href="fnm-20240930.xsd#fnm_CashCashEquivalentsAndRestrictedCashFairValueDisclosure"/>
    <link:calculationArc order="5" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AssetsFairValueDisclosure_8262566d-49ad-4f56-aa6d-6d4f57353462" xlink:to="loc_fnm_CashCashEquivalentsAndRestrictedCashFairValueDisclosure_1e88f155-677b-486d-a187-62200eebf075" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LoansReceivableFairValueDisclosure_412d0b3d-6edc-4533-9abd-8795fbb9ffed" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_LoansReceivableFairValueDisclosure"/>
    <link:calculationArc order="6" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AssetsFairValueDisclosure_8262566d-49ad-4f56-aa6d-6d4f57353462" xlink:to="loc_us-gaap_LoansReceivableFairValueDisclosure_412d0b3d-6edc-4533-9abd-8795fbb9ffed" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_TradingSecurities_444d221b-485d-4c06-a720-6706a41a34b9" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_TradingSecurities"/>
    <link:calculationArc order="7" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AssetsFairValueDisclosure_8262566d-49ad-4f56-aa6d-6d4f57353462" xlink:to="loc_us-gaap_TradingSecurities_444d221b-485d-4c06-a720-6706a41a34b9" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeAssets_26273bbf-62ba-4b22-92bf-0bdffcef0e2b" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeAssets"/>
    <link:calculationArc order="8" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AssetsFairValueDisclosure_8262566d-49ad-4f56-aa6d-6d4f57353462" xlink:to="loc_us-gaap_DerivativeAssets_26273bbf-62ba-4b22-92bf-0bdffcef0e2b" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DebtSecuritiesAvailableForSaleExcludingAccruedInterest_b74c926c-aa04-4c56-b0d4-d65d0c5931ed" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DebtSecuritiesAvailableForSaleExcludingAccruedInterest"/>
    <link:calculationArc order="9" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_AssetsFairValueDisclosure_8262566d-49ad-4f56-aa6d-6d4f57353462" xlink:to="loc_us-gaap_DebtSecuritiesAvailableForSaleExcludingAccruedInterest_b74c926c-aa04-4c56-b0d4-d65d0c5931ed" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LiabilitiesFairValueDisclosure_652f00f2-9b82-464f-a5ca-da94bd982082" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_LiabilitiesFairValueDisclosure"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_DerivativeLiabilities_19b0b46f-8a6a-4862-a0e8-6d2249f02cdc" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_DerivativeLiabilities"/>
    <link:calculationArc order="1" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesFairValueDisclosure_652f00f2-9b82-464f-a5ca-da94bd982082" xlink:to="loc_us-gaap_DerivativeLiabilities_19b0b46f-8a6a-4862-a0e8-6d2249f02cdc" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_LongTermDebtFairValue_14b66aca-9d31-42e4-8a41-bb5e5a2442d4" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_LongTermDebtFairValue"/>
    <link:calculationArc order="2" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesFairValueDisclosure_652f00f2-9b82-464f-a5ca-da94bd982082" xlink:to="loc_us-gaap_LongTermDebtFairValue_14b66aca-9d31-42e4-8a41-bb5e5a2442d4" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_GuaranteesFairValueDisclosure_5f947f88-1c6a-49ae-964a-3727ee5b7c43" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_GuaranteesFairValueDisclosure"/>
    <link:calculationArc order="3" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesFairValueDisclosure_652f00f2-9b82-464f-a5ca-da94bd982082" xlink:to="loc_us-gaap_GuaranteesFairValueDisclosure_5f947f88-1c6a-49ae-964a-3727ee5b7c43" xlink:type="arc"/>
    <link:loc xlink:type="locator" xlink:label="loc_us-gaap_ShorttermDebtFairValue_3c3d49c3-cd0c-497d-a7e8-79aeec690947" xlink:href="https://xbrl.fasb.org/us-gaap/2024/elts/us-gaap-2024.xsd#us-gaap_ShorttermDebtFairValue"/>
    <link:calculationArc order="4" weight="1.0" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="loc_us-gaap_LiabilitiesFairValueDisclosure_652f00f2-9b82-464f-a5ca-da94bd982082" xlink:to="loc_us-gaap_ShorttermDebtFairValue_3c3d49c3-cd0c-497d-a7e8-79aeec690947" xlink:type="arc"/>
  </link:calculationLink>
</link:linkbase>
