{
 "version": "2.2",
 "instance": {
  "ubsag-20240630.htm": {
   "nsprefix": "ubsag",
   "nsuri": "http://www.ubsag.com/20240630",
   "dts": {
    "inline": {
     "local": [
      "ubsag-20240630.htm"
     ]
    },
    "schema": {
     "local": [
      "ubsag-20240630.xsd"
     ],
     "remote": [
      "http://www.xbrl.org/2003/xbrl-instance-2003-12-31.xsd",
      "http://www.xbrl.org/2003/xbrl-linkbase-2003-12-31.xsd",
      "http://www.xbrl.org/2003/xl-2003-12-31.xsd",
      "http://www.xbrl.org/2003/xlink-2003-12-31.xsd",
      "http://www.xbrl.org/2005/xbrldt-2005.xsd",
      "http://www.xbrl.org/2006/ref-2006-02-27.xsd",
      "http://www.xbrl.org/lrr/role/negated-2009-12-16.xsd",
      "http://www.xbrl.org/lrr/role/reference-2009-12-16.xsd",
      "https://www.xbrl.org/2020/extensible-enumerations-2.0.xsd",
      "https://www.xbrl.org/dtr/type/2020-01-21/types.xsd",
      "https://www.xbrl.org/dtr/type/2022-03-31/types.xsd",
      "https://xbrl.fasb.org/srt/2023/elts/srt-2023.xsd",
      "https://xbrl.fasb.org/srt/2023/elts/srt-roles-2023.xsd",
      "https://xbrl.fasb.org/srt/2023/elts/srt-types-2023.xsd",
      "https://xbrl.ifrs.org/taxonomy/2023-03-23/full_ifrs/full_ifrs-cor_2023-03-23.xsd",
      "https://xbrl.sec.gov/country/2023/country-2023.xsd",
      "https://xbrl.sec.gov/dei/2023/dei-2023.xsd"
     ]
    },
    "calculationLink": {
     "local": [
      "ubsag-20240630_cal.xml"
     ]
    },
    "definitionLink": {
     "local": [
      "ubsag-20240630_def.xml"
     ]
    },
    "labelLink": {
     "local": [
      "ubsag-20240630_lab.xml"
     ]
    },
    "presentationLink": {
     "local": [
      "ubsag-20240630_pre.xml"
     ]
    }
   },
   "keyStandard": 208,
   "keyCustom": 252,
   "axisStandard": 23,
   "axisCustom": 6,
   "memberStandard": 50,
   "memberCustom": 109,
   "hidden": {
    "total": 6,
    "http://xbrl.sec.gov/dei/2023": 6
   },
   "contextCount": 1947,
   "entityCount": 1,
   "segmentCount": 167,
   "elementCount": 883,
   "unitCount": 4,
   "baseTaxonomies": {
    "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full": 3373,
    "http://xbrl.sec.gov/dei/2023": 8
   },
   "report": {
    "R1": {
     "role": "http://www.ubsag.com/role/DocumentAndEntityInformation",
     "longName": "000000 - Document - Document and Entity Information",
     "shortName": "Document and Entity Information",
     "isDefault": "true",
     "groupType": "document",
     "subGroupType": "",
     "menuCat": "Cover",
     "order": "1",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "dei:EntityRegistrantName",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "dei:EntityRegistrantName",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R2": {
     "role": "http://www.ubsag.com/role/ConsolidatedIncomeStatement",
     "longName": "001000 - Statement - Consolidated Income Statement",
     "shortName": "Consolidated Income Statement",
     "isDefault": "false",
     "groupType": "statement",
     "subGroupType": "",
     "menuCat": "Statements",
     "order": "2",
     "firstAnchor": {
      "contextRef": "FROM_Apr01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:InterestIncomeForFinancialAssetsNotAtFairValueThroughProfitOrLoss",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Apr01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:OtherNetIncomeFromFinancialInstrumentsMeasuredAtFairValueThroughProfitOrLoss",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "unique": true
     }
    },
    "R3": {
     "role": "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome",
     "longName": "001010 - Statement - Consolidated Statement of Comprehensive Income",
     "shortName": "Consolidated Statement of Comprehensive Income",
     "isDefault": "false",
     "groupType": "statement",
     "subGroupType": "",
     "menuCat": "Statements",
     "order": "3",
     "firstAnchor": {
      "contextRef": "FROM_Apr01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:ProfitLoss",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Apr01_2023_TO_Jun30_2023_Entity_0001114446",
      "name": "ifrs-full:OtherComprehensiveIncome",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "unique": true
     }
    },
    "R4": {
     "role": "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
     "longName": "001020 - Statement - Consolidated Balance Sheet",
     "shortName": "Consolidated Balance Sheet",
     "isDefault": "false",
     "groupType": "statement",
     "subGroupType": "",
     "menuCat": "Statements",
     "order": "4",
     "firstAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:CashAndBankBalancesAtCentralBanks",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:FinancialAssetsAtAmortisedCost",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "unique": true
     }
    },
    "R5": {
     "role": "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity",
     "longName": "001030 - Statement - Consolidated Statement of Changes in Equity",
     "shortName": "Consolidated Statement of Changes in Equity",
     "isDefault": "false",
     "groupType": "statement",
     "subGroupType": "",
     "menuCat": "Statements",
     "order": "5",
     "firstAnchor": {
      "contextRef": "AS_OF_Dec31_2022_Entity_0001114446_ifrs-full_ComponentsOfEquityAxis_ubsag_IssuedCapitalAndSharePremiumMember",
      "name": "ifrs-full:Equity",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Dec31_2022_Entity_0001114446_ifrs-full_ComponentsOfEquityAxis_ubsag_IssuedCapitalAndSharePremiumMember",
      "name": "ifrs-full:Equity",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R6": {
     "role": "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquityParenthetical",
     "longName": "001031 - Statement - Consolidated Statement of Changes in Equity (Parenthetical)",
     "shortName": "Consolidated Statement of Changes in Equity (Parenthetical)",
     "isDefault": "false",
     "groupType": "statement",
     "subGroupType": "parenthetical",
     "menuCat": "Statements",
     "order": "6",
     "firstAnchor": {
      "contextRef": "AS_OF_May31_2024_Entity_0001114446_ifrs-full_ComponentsOfEquityAxis_ifrs-full_NoncontrollingInterestsMember_ubsag_BusinessCombinationsUnderCommonControlAxis_ubsag_MergerWithCreditSuisseAGMember",
      "name": "ifrs-full:Equity",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_May31_2024_Entity_0001114446_ifrs-full_ComponentsOfEquityAxis_ifrs-full_NoncontrollingInterestsMember_ubsag_BusinessCombinationsUnderCommonControlAxis_ubsag_MergerWithCreditSuisseAGMember",
      "name": "ifrs-full:Equity",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R7": {
     "role": "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows",
     "longName": "001040 - Statement - Consolidated Statement of Cash Flows",
     "shortName": "Consolidated Statement of Cash Flows",
     "isDefault": "false",
     "groupType": "statement",
     "subGroupType": "",
     "menuCat": "Statements",
     "order": "7",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:ProfitLoss",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:AdjustmentsForDepreciationAndAmortisationExpenseAndImpairmentLossReversalOfImpairmentLossRecognisedInProfitOrLoss",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "unique": true
     }
    },
    "R8": {
     "role": "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlowsParenthetical",
     "longName": "001041 - Statement - Consolidated Statement of Cash Flows (Parenthetical)",
     "shortName": "Consolidated Statement of Cash Flows (Parenthetical)",
     "isDefault": "false",
     "groupType": "statement",
     "subGroupType": "parenthetical",
     "menuCat": "Statements",
     "order": "8",
     "firstAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ubsag:MoneyMarketPaperInFinancialAssetsAtFairValueNotHeldForTrading",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ubsag:MoneyMarketPaperInFinancialAssetsAtFairValueNotHeldForTrading",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R9": {
     "role": "http://www.ubsag.com/role/BasisOfAccounting",
     "longName": "100011 - Disclosure - Basis of accounting",
     "shortName": "Basis of accounting",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "9",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfMaterialAccountingPolicyInformationExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfMaterialAccountingPolicyInformationExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R10": {
     "role": "http://www.ubsag.com/role/ChangesInAccountingPoliciesComparabilityAndAdjustments",
     "longName": "100012 - Disclosure - Changes in accounting policies, comparability and adjustments",
     "shortName": "Changes in accounting policies, comparability and adjustments",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "10",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfChangesInAccountingPoliciesAccountingEstimatesAndErrorsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfChangesInAccountingPoliciesAccountingEstimatesAndErrorsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R11": {
     "role": "http://www.ubsag.com/role/CurrencyTranslationRates",
     "longName": "100013 - Disclosure - Currency translation rates",
     "shortName": "Currency translation rates",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "11",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfEffectOfChangesInForeignExchangeRatesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfEffectOfChangesInForeignExchangeRatesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R12": {
     "role": "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAG",
     "longName": "100015 - Disclosure - Accounting for the merger of UBS AG and Credit Suisse AG",
     "shortName": "Accounting for the merger of UBS AG and Credit Suisse AG",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "12",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureOfBusinessCombinationsUnderCommonControlExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureOfBusinessCombinationsUnderCommonControlExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R13": {
     "role": "http://www.ubsag.com/role/SegmentReporting",
     "longName": "100020 - Disclosure - Segment reporting",
     "shortName": "Segment reporting",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "13",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfEntitysReportableSegmentsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfEntitysReportableSegmentsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R14": {
     "role": "http://www.ubsag.com/role/NetInterestIncome",
     "longName": "100030 - Disclosure - Net interest income",
     "shortName": "Net interest income",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "14",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureNetInterestIncomeExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureNetInterestIncomeExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R15": {
     "role": "http://www.ubsag.com/role/NetFeeAndCommissionIncome",
     "longName": "100040 - Disclosure - Net fee and commission income",
     "shortName": "Net fee and commission income",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "15",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfFeeAndCommissionIncomeExpenseExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfFeeAndCommissionIncomeExpenseExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R16": {
     "role": "http://www.ubsag.com/role/OtherIncome",
     "longName": "100050 - Disclosure - Other income",
     "shortName": "Other income",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "16",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfOtherOperatingIncomeExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfOtherOperatingIncomeExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R17": {
     "role": "http://www.ubsag.com/role/PersonnelExpenses",
     "longName": "100060 - Disclosure - Personnel expenses",
     "shortName": "Personnel expenses",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "17",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfEmployeeBenefitsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfEmployeeBenefitsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R18": {
     "role": "http://www.ubsag.com/role/GeneralAndAdministrativeExpenses",
     "longName": "100070 - Disclosure - General and administrative expenses",
     "shortName": "General and administrative expenses",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "18",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfGeneralAndAdministrativeExpenseExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfGeneralAndAdministrativeExpenseExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R19": {
     "role": "http://www.ubsag.com/role/ExpectedCreditLossMeasurement",
     "longName": "100090 - Disclosure - Expected credit loss measurement",
     "shortName": "Expected credit loss measurement",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "19",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfProvisionMatrixExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfProvisionMatrixExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R20": {
     "role": "http://www.ubsag.com/role/FairValueMeasurement",
     "longName": "100100 - Disclosure - Fair value measurement",
     "shortName": "Fair value measurement",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "20",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfFairValueMeasurementExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfFairValueMeasurementExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R21": {
     "role": "http://www.ubsag.com/role/DerivativeInstruments",
     "longName": "100110 - Disclosure - Derivative instruments",
     "shortName": "Derivative instruments",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "21",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfDerivativeFinancialInstrumentsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfDerivativeFinancialInstrumentsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R22": {
     "role": "http://www.ubsag.com/role/OtherAssetsAndLiabilities",
     "longName": "100120 - Disclosure - Other assets and liabilities",
     "shortName": "Other assets and liabilities",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "22",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureOfOtherAssetsAndOtherLiabilitiesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureOfOtherAssetsAndOtherLiabilitiesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R23": {
     "role": "http://www.ubsag.com/role/FundingFromGroupMeasuredAtAmortizedCost",
     "longName": "100125 - Disclosure - Funding from Group measured at amortized cost",
     "shortName": "Funding from Group measured at amortized cost",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "23",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureOfFundingFromGroupExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureOfFundingFromGroupExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R24": {
     "role": "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValue",
     "longName": "100130 - Disclosure - Debt issued designated at fair value",
     "shortName": "Debt issued designated at fair value",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "24",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfFinancialInstrumentsDesignatedAtFairValueThroughProfitOrLossExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfFinancialInstrumentsDesignatedAtFairValueThroughProfitOrLossExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R25": {
     "role": "http://www.ubsag.com/role/DebtIssuedHeldAtAmortizedCost",
     "longName": "100150 - Disclosure - Debt issued held at amortized cost",
     "shortName": "Debt issued held at amortized cost",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "25",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfDebtSecuritiesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfDebtSecuritiesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R26": {
     "role": "http://www.ubsag.com/role/Provisions",
     "longName": "100160 - Disclosure - Provisions",
     "shortName": "Provisions",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "26",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfProvisionsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfProvisionsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R27": {
     "role": "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMatters",
     "longName": "100161 - Disclosure - Litigation, regulatory and similar matters",
     "shortName": "Litigation, regulatory and similar matters",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "27",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfContingentLiabilitiesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfContingentLiabilitiesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R28": {
     "role": "http://www.ubsag.com/role/SupplementalGuarantorInformationRequiredUnderSECRegulations",
     "longName": "100180 - Disclosure - Supplemental guarantor information required under SEC regulations",
     "shortName": "Supplemental guarantor information required under SEC regulations",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "",
     "menuCat": "Notes",
     "order": "28",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:CondensedFinancialInformationOfParentCompanyOnlyDisclosureTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:CondensedFinancialInformationOfParentCompanyOnlyDisclosureTextBlock",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R29": {
     "role": "http://www.ubsag.com/role/BasisOfAccountingPolicy",
     "longName": "200000 - Disclosure - Basis of accounting (Policy)",
     "shortName": "Basis of accounting (Policy)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "policies",
     "menuCat": "Policies",
     "order": "29",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfBasisOfPreparationOfFinancialStatementsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "ifrs-full:DisclosureOfMaterialAccountingPolicyInformationExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfBasisOfPreparationOfFinancialStatementsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "ifrs-full:DisclosureOfMaterialAccountingPolicyInformationExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R30": {
     "role": "http://www.ubsag.com/role/BasisOfAccountingTables",
     "longName": "300010 - Disclosure - Basis of accounting (Tables)",
     "shortName": "Basis of accounting (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "30",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureOfForeignExchangeRatesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureOfForeignExchangeRatesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R31": {
     "role": "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGTables",
     "longName": "300015 - Disclosure - Accounting for the merger of UBS AG and Credit Suisse AG (Tables)",
     "shortName": "Accounting for the merger of UBS AG and Credit Suisse AG (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "31",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureOfAssetsLiabilitiesAndEquityTransferredTablesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureOfAssetsLiabilitiesAndEquityTransferredTablesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R32": {
     "role": "http://www.ubsag.com/role/SegmentReportingTables",
     "longName": "300020 - Disclosure - Segment reporting (Tables)",
     "shortName": "Segment reporting (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "32",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfOperatingSegmentsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfOperatingSegmentsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R33": {
     "role": "http://www.ubsag.com/role/NetInterestIncomeTables",
     "longName": "300030 - Disclosure - Net interest income (Tables)",
     "shortName": "Net interest income (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "33",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureNetInterestIncomeTablesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureNetInterestIncomeTablesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R34": {
     "role": "http://www.ubsag.com/role/NetFeeAndCommissionIncomeTables",
     "longName": "300040 - Disclosure - Net fee and commission income (Tables)",
     "shortName": "Net fee and commission income (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "34",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureOfFeeAndCommissionIncomeExpenseTablesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureOfFeeAndCommissionIncomeExpenseTablesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R35": {
     "role": "http://www.ubsag.com/role/OtherIncomeTables",
     "longName": "300050 - Disclosure - Other income (Tables)",
     "shortName": "Other income (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "35",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureOfOtherOperatingIncomeTablesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureOfOtherOperatingIncomeTablesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R36": {
     "role": "http://www.ubsag.com/role/PersonnelExpensesTables",
     "longName": "300060 - Disclosure - Personnel expenses (Tables)",
     "shortName": "Personnel expenses (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "36",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureOfEmployeeBenefitsTablesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureOfEmployeeBenefitsTablesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R37": {
     "role": "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesTables",
     "longName": "300070 - Disclosure - General and administrative expenses (Tables)",
     "shortName": "General and administrative expenses (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "37",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureOfGeneralAndAdministrativeExpenseTablesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureOfGeneralAndAdministrativeExpenseTablesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R38": {
     "role": "http://www.ubsag.com/role/ExpectedCreditLossMeasurementTables",
     "longName": "300090 - Disclosure - Expected credit loss measurement (Tables)",
     "shortName": "Expected credit loss measurement (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "38",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureOfCreditLossExpenseRecoveryExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureOfCreditLossExpenseRecoveryExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R39": {
     "role": "http://www.ubsag.com/role/FairValueMeasurementTables",
     "longName": "300100 - Disclosure - Fair value measurement (Tables)",
     "shortName": "Fair value measurement (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "39",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfFairValueMeasurementOfAssetsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfFairValueMeasurementOfAssetsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R40": {
     "role": "http://www.ubsag.com/role/DerivativeInstrumentsTables",
     "longName": "300110 - Disclosure - Derivative instruments (Tables)",
     "shortName": "Derivative instruments (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "40",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureOfDerivativeFinancialAssetsAndLiabilitiesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureOfDerivativeFinancialAssetsAndLiabilitiesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R41": {
     "role": "http://www.ubsag.com/role/OtherAssetsAndLiabilitiesTables",
     "longName": "300120 - Disclosure - Other assets and liabilities (Tables)",
     "shortName": "Other assets and liabilities (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "41",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureOfOtherFinancialAssetsMeasuredAtAmortisedCostExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureOfOtherFinancialAssetsMeasuredAtAmortisedCostExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R42": {
     "role": "http://www.ubsag.com/role/FundingFromGroupMeasuredAtAmortizedCostTables",
     "longName": "300125 - Disclosure - Funding from Group measured at amortized cost (Tables)",
     "shortName": "Funding from Group measured at amortized cost (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "42",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureOfFundingFromGroupTablesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureOfFundingFromGroupTablesExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R43": {
     "role": "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueTable",
     "longName": "300130 - Disclosure - Debt issued designated at fair value (Table)",
     "shortName": "Debt issued designated at fair value (Table)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "43",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureOfDesignatedFinancialLiabilitiesAtFairValueThroughProfitOrLoss",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureOfDesignatedFinancialLiabilitiesAtFairValueThroughProfitOrLoss",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R44": {
     "role": "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostTables",
     "longName": "300140 - Disclosure - Debt issued measured at amortized cost (Tables)",
     "shortName": "Debt issued measured at amortized cost (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "44",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfDetailedInformationAboutBorrowingsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DisclosureOfDetailedInformationAboutBorrowingsExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R45": {
     "role": "http://www.ubsag.com/role/ProvisionsAndContingentLiabilitiesTables",
     "longName": "300160 - Disclosure - Provisions and contingent liabilities (Tables)",
     "shortName": "Provisions and contingent liabilities (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "45",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureOfProvisionsBreakdownExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureOfProvisionsBreakdownExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R46": {
     "role": "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersTables",
     "longName": "300161 - Disclosure - Litigation, regulatory and similar matters (Tables)",
     "shortName": "Litigation, regulatory and similar matters (Tables)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "tables",
     "menuCat": "Tables",
     "order": "46",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureOfLegalProceedingsProvisionExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DisclosureOfLegalProceedingsProvisionExplanatory",
      "unitRef": null,
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": null,
      "ancestors": [
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R47": {
     "role": "http://www.ubsag.com/role/BasisOfAccountingCurrencyTranslationRatesDetail",
     "longName": "400020 - Disclosure - Basis of accounting, Currency translation rates (Detail)",
     "shortName": "Basis of accounting, Currency translation rates (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "47",
     "firstAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446_ubsag_CurrencyTranslationRateAxis_ubsag_CHFCurrencyExchangeRateMember",
      "name": "ifrs-full:ClosingForeignExchangeRate",
      "unitRef": "pure",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "2",
      "ancestors": [
       "div",
       "div",
       "div",
       "ubsag:DisclosureOfForeignExchangeRatesExplanatory",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Mar31_2024_Entity_0001114446_ubsag_CurrencyTranslationRateAxis_ubsag_CHFCurrencyExchangeRateMember",
      "name": "ifrs-full:ClosingForeignExchangeRate",
      "unitRef": "pure",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "2",
      "ancestors": [
       "div",
       "div",
       "div",
       "ubsag:DisclosureOfForeignExchangeRatesExplanatory",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "unique": true
     }
    },
    "R48": {
     "role": "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail",
     "longName": "400100 - Disclosure - Accounting for the merger of UBS AG and Credit Suisse AG - Assets, liabilities and equity transferred to UBS AG on the merger date (Detail)",
     "shortName": "Accounting for the merger of UBS AG and Credit Suisse AG - Assets, liabilities and equity transferred to UBS AG on the merger date (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "48",
     "firstAnchor": {
      "contextRef": "AS_OF_May31_2024_Entity_0001114446_ubsag_BusinessCombinationsUnderCommonControlAxis_ubsag_MergerWithCreditSuisseAGMember",
      "name": "ubsag:CashAndBankBalancesAtCentralBanksTransferredAsOfTheMergerDate",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureOfAssetsLiabilitiesAndEquityTransferredTablesExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_May31_2024_Entity_0001114446_ubsag_BusinessCombinationsUnderCommonControlAxis_ubsag_MergerWithCreditSuisseAGMember",
      "name": "ubsag:CashAndBankBalancesAtCentralBanksTransferredAsOfTheMergerDate",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureOfAssetsLiabilitiesAndEquityTransferredTablesExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R49": {
     "role": "http://www.ubsag.com/role/SegmentReportingNarrativeDetail",
     "longName": "401098 - Disclosure - Segment reporting (Narrative) (Detail)",
     "shortName": "Segment reporting (Narrative) (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "49",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2023_TO_Jun30_2023_Entity_0001114446_ifrs-full_SegmentsAxis_ubsag_SegmentGWMMember",
      "name": "ubsag:IncreaseDecreaseInProfitLossBeforeTaxRestatementResult",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2023_TO_Jun30_2023_Entity_0001114446_ifrs-full_SegmentsAxis_ubsag_SegmentGWMMember",
      "name": "ubsag:IncreaseDecreaseInProfitLossBeforeTaxRestatementResult",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R50": {
     "role": "http://www.ubsag.com/role/SegmentReportingDetail",
     "longName": "401100 - Disclosure - Segment reporting (Detail)",
     "shortName": "Segment reporting (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "50",
     "firstAnchor": {
      "contextRef": "FROM_Apr01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:InterestRevenueExpense",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:NoninterestIncome",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ifrs-full:DisclosureOfOperatingSegmentsExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "unique": true
     }
    },
    "R51": {
     "role": "http://www.ubsag.com/role/NetInterestIncomeDetail",
     "longName": "401105 - Disclosure - Net interest income (Detail)",
     "shortName": "Net interest income (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "51",
     "firstAnchor": {
      "contextRef": "FROM_Apr01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:InterestIncomeFromLoansAndDeposits",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureNetInterestIncomeTablesExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Apr01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:InterestIncomeFromLoansAndDeposits",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureNetInterestIncomeTablesExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R52": {
     "role": "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail",
     "longName": "401110 - Disclosure - Net fee and commission income (Detail)",
     "shortName": "Net fee and commission income (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "52",
     "firstAnchor": {
      "contextRef": "FROM_Apr01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:UnderwritingFees",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureOfFeeAndCommissionIncomeExpenseTablesExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Apr01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:UnderwritingFees",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureOfFeeAndCommissionIncomeExpenseTablesExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R53": {
     "role": "http://www.ubsag.com/role/OtherIncomeDetail",
     "longName": "401120 - Disclosure - Other income (Detail)",
     "shortName": "Other income (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "53",
     "firstAnchor": {
      "contextRef": "FROM_Apr01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:GainsLossesFromAcquisitionsAndDisposalsOfSubsidiaries",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ubsag:DisclosureOfOtherOperatingIncomeTablesExplanatory",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Apr01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:GainsLossesFromAcquisitionsAndDisposalsOfSubsidiaries",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ubsag:DisclosureOfOtherOperatingIncomeTablesExplanatory",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R54": {
     "role": "http://www.ubsag.com/role/PersonnelExpensesDetail",
     "longName": "401130 - Disclosure - Personnel expenses (Detail)",
     "shortName": "Personnel expenses (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "54",
     "firstAnchor": {
      "contextRef": "FROM_Apr01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:WagesAndSalariesAndVariableCompensation",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureOfEmployeeBenefitsTablesExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Apr01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:WagesAndSalariesAndVariableCompensation",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureOfEmployeeBenefitsTablesExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R55": {
     "role": "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesDetail",
     "longName": "401140 - Disclosure - General and administrative expenses (Detail)",
     "shortName": "General and administrative expenses (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "55",
     "firstAnchor": {
      "contextRef": "FROM_Apr01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:OutsourcingExpense",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureOfGeneralAndAdministrativeExpenseTablesExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Apr01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:OutsourcingExpense",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureOfGeneralAndAdministrativeExpenseTablesExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R56": {
     "role": "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpenseReleaseNarrativeDetail",
     "longName": "401150 - Disclosure - Expected credit loss measurement - Credit loss expense / release (Narrative) (Detail)",
     "shortName": "Expected credit loss measurement - Credit loss expense / release (Narrative) (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "56",
     "firstAnchor": {
      "contextRef": "FROM_Apr01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:ImpairmentLossImpairmentGainAndReversalOfImpairmentLossDeterminedInAccordanceWithIFRS9",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Apr01_2024_TO_Jun30_2024_Entity_0001114446_ifrs-full_CreditImpairmentOfFinancialInstrumentsAxis_ifrs-full_FinancialInstrumentsNotCreditimpairedMember_ifrs-full_ImpairmentOfFinancialAssetsAxis_ubsag_ChangesInExpectedCreditLossesScenariosMember",
      "name": "ifrs-full:ImpairmentLossImpairmentGainAndReversalOfImpairmentLossDeterminedInAccordanceWithIFRS9",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "unique": true
     }
    },
    "R57": {
     "role": "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpensereleaseDetail",
     "longName": "401152 - Disclosure - Expected credit loss measurement - Credit loss expense / (release) (Detail)",
     "shortName": "Expected credit loss measurement - Credit loss expense / (release) (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "57",
     "firstAnchor": {
      "contextRef": "FROM_Apr01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:ImpairmentLossImpairmentGainAndReversalOfImpairmentLossDeterminedInAccordanceWithIFRS9",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Apr01_2024_TO_Jun30_2024_Entity_0001114446_ifrs-full_CreditImpairmentOfFinancialInstrumentsAxis_ifrs-full_FinancialInstrumentsNotCreditimpairedMember_ifrs-full_SegmentsAxis_ubsag_SegmentGWMMember",
      "name": "ifrs-full:ImpairmentLossImpairmentGainAndReversalOfImpairmentLossDeterminedInAccordanceWithIFRS9",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureOfCreditLossExpenseRecoveryExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "unique": true
     }
    },
    "R58": {
     "role": "http://www.ubsag.com/role/ExpectedCreditLossMeasurementChangesToECLModelsScenariosScenarioWeightsAndPostmodelAdjustmentsNarrativeDetail",
     "longName": "401153 - Disclosure - Expected credit loss measurement - Changes to ECL models, scenarios, scenario weights and post-model adjustments (Narrative) (Detail)",
     "shortName": "Expected credit loss measurement - Changes to ECL models, scenarios, scenario weights and post-model adjustments (Narrative) (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "58",
     "firstAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ubsag:AllowanceForCreditLossesOnFinancialAssetsAndProvisionsForExpectedCreditLossesOnLoanCommitmentsAndFinancialGuaranteeContracts",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ifrs-full:DisclosureOfCreditRiskExposureExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446_ifrs-full_CreditImpairmentOfFinancialInstrumentsAxis_ifrs-full_FinancialInstrumentsNotCreditimpairedMember_ifrs-full_ImpairmentOfFinancialAssetsAxis_ubsag_PostModelCreditLossExpenseAdjustmentMember",
      "name": "ubsag:AllowanceForCreditLossesOnFinancialAssetsAndProvisionsForExpectedCreditLossesOnLoanCommitmentsAndFinancialGuaranteeContracts",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "unique": true
     }
    },
    "R59": {
     "role": "http://www.ubsag.com/role/ExpectedCreditLossMeasurementComparisonOfShockFactorsDetail",
     "longName": "401155 - Disclosure - Expected credit loss measurement - Comparison of shock factors  (Detail)",
     "shortName": "Expected credit loss measurement - Comparison of shock factors  (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "59",
     "firstAnchor": {
      "contextRef": "FROM_Apr01_2024_TO_Jun30_2024_Entity_0001114446_ifrs-full_GeographicalAreasAxis_country_US_ifrs-full_MaturityAxis_ifrs-full_OneYearBeforeReportingYearMember_ubsag_EconomicAssumptionsAxis_ubsag_GrossDomesticProductMember_ubsag_ExpectedCreditLossesEconomicScenarioAxis_ubsag_BaselineScenarioMember",
      "name": "ubsag:EconomicForecast",
      "unitRef": "pure",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "5",
      "ancestors": [
       "div",
       "div",
       "div",
       "ubsag:DisclosureOfKeyMacroEconomicVariablesExplanatory",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Apr01_2024_TO_Jun30_2024_Entity_0001114446_ifrs-full_GeographicalAreasAxis_country_US_ifrs-full_MaturityAxis_ifrs-full_OneYearBeforeReportingYearMember_ubsag_EconomicAssumptionsAxis_ubsag_GrossDomesticProductMember_ubsag_ExpectedCreditLossesEconomicScenarioAxis_ubsag_BaselineScenarioMember",
      "name": "ubsag:EconomicForecast",
      "unitRef": "pure",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "5",
      "ancestors": [
       "div",
       "div",
       "div",
       "ubsag:DisclosureOfKeyMacroEconomicVariablesExplanatory",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R60": {
     "role": "http://www.ubsag.com/role/ExpectedCreditLossMeasurementEconomicScenariosAndWeightsAppliedDetail",
     "longName": "401156 - Disclosure - Expected credit loss measurement - Economic scenarios and weights applied (Detail)",
     "shortName": "Expected credit loss measurement - Economic scenarios and weights applied (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "60",
     "firstAnchor": {
      "contextRef": "FROM_Apr01_2024_TO_Jun30_2024_Entity_0001114446_ubsag_ExpectedCreditLossesEconomicScenarioAxis_ubsag_BaselineScenarioMember",
      "name": "ubsag:ScenarioWeights",
      "unitRef": "pure",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "5",
      "ancestors": [
       "div",
       "div",
       "div",
       "ubsag:DisclosureOfKeyMacroEconomicVariablesExplanatory",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Apr01_2024_TO_Jun30_2024_Entity_0001114446_ubsag_ExpectedCreditLossesEconomicScenarioAxis_ubsag_BaselineScenarioMember",
      "name": "ubsag:ScenarioWeights",
      "unitRef": "pure",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "5",
      "ancestors": [
       "div",
       "div",
       "div",
       "ubsag:DisclosureOfKeyMacroEconomicVariablesExplanatory",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R61": {
     "role": "http://www.ubsag.com/role/ExpectedCreditLossMeasurementECLrelevantBalanceSheetAndOffbalanceSheetPositionsIncludingECLAllowancesAndProvisionsNarrativeDetail",
     "longName": "401157 - Disclosure - Expected credit loss measurement - ECL-relevant balance sheet and off-balance sheet positions including ECL allowances and provisions (Narrative) (Detail)",
     "shortName": "Expected credit loss measurement - ECL-relevant balance sheet and off-balance sheet positions including ECL allowances and provisions (Narrative) (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "61",
     "firstAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:ExpectedCreditLossRate",
      "unitRef": "pure",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "8",
      "ancestors": [
       "div",
       "div",
       "div",
       "ubsag:DisclosureOfCoverageRatiosExplanatory",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true
     },
     "uniqueAnchor": null
    },
    "R62": {
     "role": "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail",
     "longName": "401160 - Disclosure - Expected credit loss measurement - On-balance sheet financial assets subject to ECL (Detail)",
     "shortName": "Expected credit loss measurement - On-balance sheet financial assets subject to ECL (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "62",
     "firstAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ubsag:AllowanceForCreditLossesOnFinancialAssetsAndProvisionsForExpectedCreditLossesOnLoanCommitmentsAndFinancialGuaranteeContracts",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ifrs-full:DisclosureOfCreditRiskExposureExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446_ifrs-full_ClassesOfFinancialInstrumentsAxis_ubsag_CashAndBankBalancesAtCentralBanksMember",
      "name": "ifrs-full:FinancialAssets",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ifrs-full:DisclosureOfCreditRiskExposureExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "unique": true
     }
    },
    "R63": {
     "role": "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail",
     "longName": "401161 - Disclosure - Expected credit loss measurement - Off-balance sheet financial assets subject to ECL (Detail)",
     "shortName": "Expected credit loss measurement - Off-balance sheet financial assets subject to ECL (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "63",
     "firstAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:ExposureToCreditRiskOnLoanCommitmentsAndFinancialGuaranteeContracts",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ifrs-full:DisclosureOfCreditRiskExposureExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446_ifrs-full_ClassesOfFinancialInstrumentsAxis_ifrs-full_FinancialGuaranteeContractsMember",
      "name": "ifrs-full:ExposureToCreditRiskOnLoanCommitmentsAndFinancialGuaranteeContracts",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ifrs-full:DisclosureOfCreditRiskExposureExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "unique": true
     }
    },
    "R64": {
     "role": "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
     "longName": "401165 - Disclosure - Expected credit loss measurement - Coverage ratios (Detail 1)",
     "shortName": "Expected credit loss measurement - Coverage ratios (Detail 1)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "64",
     "firstAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ubsag:FinancialAssetsAndExposureToCreditRiskOnLoanCommitmentsAndFinancialGuaranteeContractsInCoreLoanPortfolio",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ubsag:DisclosureOfCoverageRatiosExplanatory",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446_ifrs-full_CarryingAmountAccumulatedDepreciationAmortisationAndImpairmentAndGrossCarryingAmountAxis_ifrs-full_GrossCarryingAmountMember_ifrs-full_ClassesOfFinancialInstrumentsAxis_ubsag_OnbalanceSheetLoanPortfolioMember",
      "name": "ifrs-full:FinancialAssets",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ubsag:DisclosureOfCoverageRatiosExplanatory",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "unique": true
     }
    },
    "R65": {
     "role": "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
     "longName": "401166 - Disclosure - Expected credit loss measurement - Coverage ratios (Detail 2)",
     "shortName": "Expected credit loss measurement - Coverage ratios (Detail 2)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "65",
     "firstAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:ExposureToCreditRiskOnLoanCommitmentsAndFinancialGuaranteeContracts",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ifrs-full:DisclosureOfCreditRiskExposureExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446_ifrs-full_ClassesOfFinancialInstrumentsAxis_ubsag_OffbalanceSheetLoanPortfolioMember",
      "name": "ifrs-full:ExposureToCreditRiskOnLoanCommitmentsAndFinancialGuaranteeContracts",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ubsag:DisclosureOfCoverageRatiosExplanatory",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "unique": true
     }
    },
    "R66": {
     "role": "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail",
     "longName": "401170 - Disclosure - FVM - Fair value hierarchy - Assets (Detail)",
     "shortName": "FVM - Fair value hierarchy - Assets (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "66",
     "firstAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:FinancialAssetsAtFairValueThroughProfitOrLossClassifiedAsHeldForTrading",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ubsag:PreciousMetalsAndOtherPhysicalCommoditiesMeasuredAtFairValue",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ifrs-full:DisclosureOfFairValueMeasurementOfAssetsExplanatory",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "unique": true
     }
    },
    "R67": {
     "role": "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail",
     "longName": "401171 - Disclosure - FVM - Fair value hierarchy - Liabilities (Detail)",
     "shortName": "FVM - Fair value hierarchy - Liabilities (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "67",
     "firstAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:FinancialLiabilitiesAtFairValueThroughProfitOrLossClassifiedAsHeldForTrading",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446_ubsag_FinancialInstrumentAxis_ifrs-full_EquityInvestmentsMember",
      "name": "ifrs-full:FinancialLiabilitiesAtFairValueThroughProfitOrLossClassifiedAsHeldForTrading",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ifrs-full:DisclosureOfFairValueMeasurementOfLiabilitiesExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "unique": true
     }
    },
    "R68": {
     "role": "http://www.ubsag.com/role/FVMValuationAdjustmentsReservesOnTheBalanceSheetDetail",
     "longName": "401179 - Disclosure - FVM - Valuation adjustments reserves on the balance sheet (Detail)",
     "shortName": "FVM - Valuation adjustments reserves on the balance sheet (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "68",
     "firstAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:ReserveOfChangeInFairValueOfFinancialLiabilityAttributableToChangeInCreditRiskOfLiability",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ubsag:DisclosureOfValuationAdjustmentReservesOnTheBalanceSheetExplanatory",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:ReserveOfChangeInFairValueOfFinancialLiabilityAttributableToChangeInCreditRiskOfLiability",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ubsag:DisclosureOfValuationAdjustmentReservesOnTheBalanceSheetExplanatory",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R69": {
     "role": "http://www.ubsag.com/role/FVMValuationAdjustmentsDeferredDay1PLDetail",
     "longName": "401180 - Disclosure - FVM - Valuation adjustments: Deferred day-1 P&L (Detail)",
     "shortName": "FVM - Valuation adjustments: Deferred day-1 P&L (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "69",
     "firstAnchor": {
      "contextRef": "AS_OF_Mar31_2024_Entity_0001114446",
      "name": "ifrs-full:AggregateDifferenceBetweenFairValueAtInitialRecognitionAndAmountDeterminedUsingValuationTechniqueYetToBeRecognised",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureOfDeferredDayOneProfitOrLossExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Mar31_2023_Entity_0001114446",
      "name": "ifrs-full:AggregateDifferenceBetweenFairValueAtInitialRecognitionAndAmountDeterminedUsingValuationTechniqueYetToBeRecognised",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureOfDeferredDayOneProfitOrLossExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "unique": true
     }
    },
    "R70": {
     "role": "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail",
     "longName": "401190 - Disclosure - FVM - Level 3 instruments: Valuation techniques and inputs (Detail)",
     "shortName": "FVM - Level 3 instruments: Valuation techniques and inputs (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "70",
     "firstAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446_ifrs-full_LevelsOfFairValueHierarchyAxis_ifrs-full_Level3OfFairValueHierarchyMember_ubsag_FinancialInstrumentAxis_ubsag_CorporateAndMunicipalBondsMember",
      "name": "ifrs-full:FinancialAssetsAtFairValue",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-8",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureOfSignificantUnobservableInputsUsedInFairValueMeasurementOfAssetsAndLiabilitiesExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446_ifrs-full_LevelsOfFairValueHierarchyAxis_ifrs-full_Level3OfFairValueHierarchyMember_ubsag_FinancialInstrumentAxis_ubsag_CorporateAndMunicipalBondsMember",
      "name": "ifrs-full:FinancialLiabilitiesAtFairValue",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-8",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureOfSignificantUnobservableInputsUsedInFairValueMeasurementOfAssetsAndLiabilitiesExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "unique": true
     }
    },
    "R71": {
     "role": "http://www.ubsag.com/role/FVMLevel3InstrumentsSensitivityToChangesInUnobservableInputAssumptionsDetail",
     "longName": "401200 - Disclosure - FVM - Level 3 instruments: Sensitivity to changes in unobservable input assumptions (Detail)",
     "shortName": "FVM - Level 3 instruments: Sensitivity to changes in unobservable input assumptions (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "71",
     "firstAnchor": {
      "contextRef": "FROM_Apr01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:IncreaseInFairValueMeasurementDueToChangeInMultipleUnobservableInputsToReflectReasonablyPossibleAlternativeAssumptionsAssetsAndLiabilities",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureOfSensitivityAnalysisOfFairValueMeasurementToChangesInUnobservableInputsAssetsAndLiabilitiesExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "FROM_Apr01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ubsag:IncreaseInFairValueMeasurementDueToChangeInMultipleUnobservableInputsToReflectReasonablyPossibleAlternativeAssumptionsAssetsAndLiabilities",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureOfSensitivityAnalysisOfFairValueMeasurementToChangesInUnobservableInputsAssetsAndLiabilitiesExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R72": {
     "role": "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail",
     "longName": "401210 - Disclosure - FVM - Movements of level 3 instruments - Assets (Detail)",
     "shortName": "FVM - Movements of level 3 instruments - Assets (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "72",
     "firstAnchor": {
      "contextRef": "AS_OF_Dec31_2023_Entity_0001114446_ifrs-full_LevelsOfFairValueHierarchyAxis_ifrs-full_Level3OfFairValueHierarchyMember_ubsag_FinancialInstrumentAxis_ifrs-full_InvestmentFundsMember",
      "name": "ifrs-full:FinancialAssetsAtFairValue",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-8",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureOfSignificantUnobservableInputsUsedInFairValueMeasurementOfAssetsAndLiabilitiesExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Dec31_2023_Entity_0001114446_ifrs-full_CategoriesOfFinancialAssetsAxis_ifrs-full_FinancialAssetsAtFairValueThroughProfitOrLossClassifiedAsHeldForTradingCategoryMember_ifrs-full_LevelsOfFairValueHierarchyAxis_ifrs-full_Level3OfFairValueHierarchyMember",
      "name": "ifrs-full:FinancialAssetsAtFairValue",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-8",
      "ancestors": [
       "div",
       "div",
       "div",
       "ubsag:DisclosureOfLevel3OfFairValueOfFinancialInstrumentsExplanatory",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "unique": true
     }
    },
    "R73": {
     "role": "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail",
     "longName": "401211 - Disclosure - FVM - Movements of level 3 instruments - Liabilities (Detail)",
     "shortName": "FVM - Movements of level 3 instruments - Liabilities (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "73",
     "firstAnchor": {
      "contextRef": "AS_OF_Dec31_2023_Entity_0001114446_ifrs-full_LevelsOfFairValueHierarchyAxis_ifrs-full_Level3OfFairValueHierarchyMember_ubsag_FinancialInstrumentAxis_ifrs-full_LoanCommitmentsMember",
      "name": "ifrs-full:FinancialLiabilitiesAtFairValue",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-8",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureOfSignificantUnobservableInputsUsedInFairValueMeasurementOfAssetsAndLiabilitiesExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Dec31_2023_Entity_0001114446_ifrs-full_CategoriesOfFinancialLiabilitiesAxis_ifrs-full_DerivativesMember_ifrs-full_LevelsOfFairValueHierarchyAxis_ifrs-full_Level3OfFairValueHierarchyMember",
      "name": "ifrs-full:FinancialLiabilitiesAtFairValue",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-8",
      "ancestors": [
       "div",
       "div",
       "div",
       "ubsag:DisclosureOfLevel3OfFairValueOfFinancialInstrumentsExplanatory",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "unique": true
     }
    },
    "R74": {
     "role": "http://www.ubsag.com/role/FVMFinancialInstrumentsNotMeasuredAtFairValueAssetsDetail",
     "longName": "401220 - Disclosure - FVM - Financial instruments not measured at fair value - Assets (Detail)",
     "shortName": "FVM - Financial instruments not measured at fair value - Assets (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "74",
     "firstAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:CashAndBankBalancesAtCentralBanks",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446_ifrs-full_MeasurementAxis_ifrs-full_NotMeasuredAtFairValueInStatementOfFinancialPositionButForWhichFairValueIsDisclosedMember",
      "name": "ifrs-full:CashAndBankBalancesAtCentralBanks",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-8",
      "ancestors": [
       "div",
       "div",
       "div",
       "ubsag:DisclosureOfFairValueOfFinancialInstrumentsNotMeasuredAtFairValueExplanatory",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "unique": true
     }
    },
    "R75": {
     "role": "http://www.ubsag.com/role/FVMFinancialInstrumentsNotMeasuredAtFairValueLiabilitiesDetail",
     "longName": "401221 - Disclosure - FVM - Financial instruments not measured at fair value - Liabilities (Detail)",
     "shortName": "FVM - Financial instruments not measured at fair value - Liabilities (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "75",
     "firstAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DepositsFromBanks",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ubsag:OtherFinancialLiabilitiesAtAmortisedCostExcludingLeaseLiabilities",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-8",
      "ancestors": [
       "div",
       "div",
       "div",
       "ubsag:DisclosureOfFairValueOfFinancialInstrumentsNotMeasuredAtFairValueExplanatory",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "unique": true
     }
    },
    "R76": {
     "role": "http://www.ubsag.com/role/DerivativeInstrumentsDetail",
     "longName": "401230 - Disclosure - Derivative instruments (Detail)",
     "shortName": "Derivative instruments (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "76",
     "firstAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:DerivativeFinancialAssets",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DerivativeAssetsAndLiabilitiesNotionalAmount",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-8",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureOfDerivativeFinancialAssetsAndLiabilitiesExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "unique": true
     }
    },
    "R77": {
     "role": "http://www.ubsag.com/role/OffsettingFinancialAssetsDetail",
     "longName": "401240 - Disclosure - Offsetting financial assets (Detail)",
     "shortName": "Offsetting financial assets (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "77",
     "firstAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446_ifrs-full_TypesOfFinancialAssetsAxis_ifrs-full_DerivativesMember",
      "name": "ifrs-full:AmountsSubjectToEnforceableMasterNettingArrangementOrSimilarAgreementNotSetOffAgainstFinancialAssets",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-8",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureOfDerivativeFinancialAssetsAndLiabilitiesExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446_ifrs-full_TypesOfFinancialAssetsAxis_ifrs-full_DerivativesMember",
      "name": "ifrs-full:AmountsSubjectToEnforceableMasterNettingArrangementOrSimilarAgreementNotSetOffAgainstFinancialAssets",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-8",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureOfDerivativeFinancialAssetsAndLiabilitiesExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R78": {
     "role": "http://www.ubsag.com/role/OffsettingFinancialLiabilitiesDetail",
     "longName": "401241 - Disclosure - Offsetting financial liabilities (Detail)",
     "shortName": "Offsetting financial liabilities (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "78",
     "firstAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446_ifrs-full_TypesOfFinancialLiabilitiesAxis_ifrs-full_DerivativesMember",
      "name": "ifrs-full:AmountsSubjectToEnforceableMasterNettingArrangementOrSimilarAgreementNotSetOffAgainstFinancialLiabilities",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-8",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureOfDerivativeFinancialAssetsAndLiabilitiesExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446_ifrs-full_TypesOfFinancialLiabilitiesAxis_ifrs-full_DerivativesMember",
      "name": "ifrs-full:AmountsSubjectToEnforceableMasterNettingArrangementOrSimilarAgreementNotSetOffAgainstFinancialLiabilities",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-8",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureOfDerivativeFinancialAssetsAndLiabilitiesExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R79": {
     "role": "http://www.ubsag.com/role/OtherFinancialAssetsMeasuredAtAmortizedCostDetail",
     "longName": "401250 - Disclosure - Other financial assets measured at amortized cost (Detail)",
     "shortName": "Other financial assets measured at amortized cost (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "79",
     "firstAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DebtInstrumentsHeldMeasuredAtAmortizedCost",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureOfOtherFinancialAssetsMeasuredAtAmortisedCostExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ubsag:DebtInstrumentsHeldMeasuredAtAmortizedCost",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureOfOtherFinancialAssetsMeasuredAtAmortisedCostExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R80": {
     "role": "http://www.ubsag.com/role/OtherNonfinancialAssetsDetail",
     "longName": "401260 - Disclosure - Other non-financial assets (Detail)",
     "shortName": "Other non-financial assets (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "80",
     "firstAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ubsag:PreciousMetalsAndOtherPhysicalCommodities",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ubsag:DisclosureOfOtherNonFinancialAssetsExplanatory",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ubsag:PreciousMetalsAndOtherPhysicalCommodities",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ubsag:DisclosureOfOtherNonFinancialAssetsExplanatory",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R81": {
     "role": "http://www.ubsag.com/role/OtherFinancialLiabilitiesMeasuredAtAmortizedCostDetail",
     "longName": "401270 - Disclosure - Other financial liabilities measured at amortized cost (Detail)",
     "shortName": "Other financial liabilities measured at amortized cost (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "81",
     "firstAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:CurrentAccruedExpensesAndOtherCurrentLiabilities",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ubsag:DisclosureOfOtherFinancialLiabilitiesMeasuredAtAmortizedCostExplanatory",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:CurrentAccruedExpensesAndOtherCurrentLiabilities",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ubsag:DisclosureOfOtherFinancialLiabilitiesMeasuredAtAmortizedCostExplanatory",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R82": {
     "role": "http://www.ubsag.com/role/OtherFinancialLiabilitiesDesignatedAtFairValueDetail",
     "longName": "401280 - Disclosure - Other financial liabilities designated at fair value (Detail)",
     "shortName": "Other financial liabilities designated at fair value (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "82",
     "firstAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ubsag:AmountDueUnderUnitLinkedInvestmentContracts",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ubsag:DisclosureOfOtherFinancialLiabilitiesMeasuredAtFairValueExplanatory",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ubsag:AmountDueUnderUnitLinkedInvestmentContracts",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ubsag:DisclosureOfOtherFinancialLiabilitiesMeasuredAtFairValueExplanatory",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R83": {
     "role": "http://www.ubsag.com/role/OtherNonfinancialLiabilitiesDetail",
     "longName": "401290 - Disclosure - Other non-financial liabilities (Detail)",
     "shortName": "Other non-financial liabilities (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "83",
     "firstAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ubsag:CompensationrelatedLiabilities",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ubsag:DisclosureOfOtherNonFinancialLiabilitiesExplanatory",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ubsag:CompensationrelatedLiabilities",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ubsag:DisclosureOfOtherNonFinancialLiabilitiesExplanatory",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R84": {
     "role": "http://www.ubsag.com/role/FundingFromGroupMeasuredAtAmortizedCostDetail",
     "longName": "401295 - Disclosure - Funding from Group measured at amortized cost (Detail)",
     "shortName": "Funding from Group measured at amortized cost (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "84",
     "firstAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ubsag:TLACEligibleSubordinatedDebtInstrumentsAtAmortizedCostInGoneConcernLossAbsorbingCapacityIntragroupFunding",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureOfFundingFromGroupTablesExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ubsag:TLACEligibleSubordinatedDebtInstrumentsAtAmortizedCostInGoneConcernLossAbsorbingCapacityIntragroupFunding",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureOfFundingFromGroupTablesExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R85": {
     "role": "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueDetail",
     "longName": "401300 - Disclosure - Debt issued designated at fair value (Detail)",
     "shortName": "Debt issued designated at fair value (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "85",
     "firstAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ubsag:EquityLinkedIssuedDebtInstrumentsDesignatedAtFairValueThroughProfitOrLoss",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureOfDesignatedFinancialLiabilitiesAtFairValueThroughProfitOrLoss",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ubsag:EquityLinkedIssuedDebtInstrumentsDesignatedAtFairValueThroughProfitOrLoss",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureOfDesignatedFinancialLiabilitiesAtFairValueThroughProfitOrLoss",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R86": {
     "role": "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostDetail",
     "longName": "401310 - Disclosure - Debt issued measured at amortized cost (Detail)",
     "shortName": "Debt issued measured at amortized cost (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "86",
     "firstAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:CurrentDebtInstrumentsIssued",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ifrs-full:DisclosureOfDetailedInformationAboutBorrowingsExplanatory",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:CurrentDebtInstrumentsIssued",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ifrs-full:DisclosureOfDetailedInformationAboutBorrowingsExplanatory",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R87": {
     "role": "http://www.ubsag.com/role/ProvisionsDetail",
     "longName": "401320 - Disclosure - Provisions (Detail)",
     "shortName": "Provisions (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "87",
     "firstAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ubsag:ProvisionsOtherThanProvisionsForExpectedCreditLosses",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureOfProvisionsBreakdownExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true
     },
     "uniqueAnchor": null
    },
    "R88": {
     "role": "http://www.ubsag.com/role/ProvisionsAdditionalInformationDetail",
     "longName": "401330 - Disclosure - Provisions - additional information (Detail)",
     "shortName": "Provisions - additional information (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "88",
     "firstAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ubsag:ProvisionsOtherThanProvisionsForExpectedCreditLosses",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureOfProvisionsBreakdownExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Dec31_2023_Entity_0001114446_ifrs-full_ClassesOfProvisionsAxis_ifrs-full_RestructuringProvisionMember",
      "name": "ubsag:ProvisionsOtherThanProvisionsForExpectedCreditLosses",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ifrs-full:DisclosureOfOtherProvisionsExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "unique": true
     }
    },
    "R89": {
     "role": "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersDetail",
     "longName": "401340 - Disclosure - Litigation, regulatory and similar matters (Detail)",
     "shortName": "Litigation, regulatory and similar matters (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "89",
     "firstAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ubsag:ProvisionsOtherThanProvisionsForExpectedCreditLosses",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "ubsag:DisclosureOfProvisionsBreakdownExplanatory",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Dec31_2023_Entity_0001114446_ifrs-full_ClassesOfProvisionsAxis_ifrs-full_LegalProceedingsProvisionMember_ifrs-full_SegmentsAxis_ubsag_SegmentGWMMember",
      "name": "ubsag:ProvisionsOtherThanProvisionsForExpectedCreditLosses",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "ubsag:DisclosureOfLegalProceedingsProvisionExplanatory",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "unique": true
     }
    },
    "R90": {
     "role": "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail",
     "longName": "401343 - Disclosure - Litigation, regulatory and similar matters (Narrative) (Detail)",
     "shortName": "Litigation, regulatory and similar matters (Narrative) (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "90",
     "firstAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446_ifrs-full_ClassesOfProvisionsAxis_ifrs-full_LegalProceedingsProvisionMember_ifrs-full_RangeAxis_ifrs-full_BottomOfRangeMember",
      "name": "ubsag:EstimatedLossesNotCoveredByExistingProvisions",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-9",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446_ifrs-full_ClassesOfProvisionsAxis_ifrs-full_LegalProceedingsProvisionMember_ifrs-full_RangeAxis_ifrs-full_BottomOfRangeMember",
      "name": "ubsag:EstimatedLossesNotCoveredByExistingProvisions",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-9",
      "ancestors": [
       "div",
       "div",
       "div",
       "ix:continuation",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R91": {
     "role": "http://www.ubsag.com/role/SupplementalGuarantorInformationNarrativeDetail",
     "longName": "401379 - Disclosure - Supplemental guarantor information (Narrative) (Detail)",
     "shortName": "Supplemental guarantor information (Narrative) (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "91",
     "firstAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ubsag:JointAndSeveralLiability",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-8",
      "ancestors": [
       "div",
       "div",
       "div",
       "ubsag:CondensedFinancialInformationOfParentCompanyOnlyDisclosureTextBlock",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     },
     "uniqueAnchor": {
      "contextRef": "AS_OF_Jun30_2024_Entity_0001114446",
      "name": "ubsag:JointAndSeveralLiability",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-8",
      "ancestors": [
       "div",
       "div",
       "div",
       "ubsag:CondensedFinancialInformationOfParentCompanyOnlyDisclosureTextBlock",
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true,
      "unique": true
     }
    },
    "R92": {
     "role": "http://www.ubsag.com/role/SupplementalGuarantorConsolidatedStatementOfCashFlowsDetail",
     "longName": "401410 - Disclosure - Supplemental guarantor consolidated statement of cash flows (Detail)",
     "shortName": "Supplemental guarantor consolidated statement of cash flows (Detail)",
     "isDefault": "false",
     "groupType": "disclosure",
     "subGroupType": "details",
     "menuCat": "Details",
     "order": "92",
     "firstAnchor": {
      "contextRef": "FROM_Jan01_2024_TO_Jun30_2024_Entity_0001114446",
      "name": "ifrs-full:CashFlowsFromUsedInOperatingActivities",
      "unitRef": "USD",
      "xsiNil": "false",
      "lang": "en-US",
      "decimals": "-6",
      "ancestors": [
       "div",
       "div",
       "div",
       "div",
       "body",
       "html"
      ],
      "reportCount": 1,
      "baseRef": "ubsag-20240630.htm",
      "first": true
     },
     "uniqueAnchor": null
    }
   },
   "tag": {
    "ifrs-full_AccumulatedOtherComprehensiveIncome": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "AccumulatedOtherComprehensiveIncome",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_EquityAttributableToOwnersOfParent",
       "weight": 1.0,
       "order": 46.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Accumulated Other Comprehensive Income",
        "terseLabel": "Other comprehensive income recognized directly in equity, net of tax"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of accumulated items of income and expense (including reclassification adjustments) that are not recognised in profit or loss as required or permitted by other IFRSs. [Refer: IFRSs [member]; Other comprehensive income]"
       }
      }
     },
     "auth_ref": [
      "r249"
     ]
    },
    "ifrs-full_AdditionalInformationAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "AdditionalInformationAbstract",
     "presentation": [
      "http://www.ubsag.com/role/SegmentReportingDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Additional Information [Abstract]",
        "terseLabel": "Additional information"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_AdditionalProvisionsOtherProvisions": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "AdditionalProvisionsOtherProvisions",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersDetail",
      "http://www.ubsag.com/role/ProvisionsAdditionalInformationDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Additional Provisions Other Provisions",
        "terseLabel": "Increase in provisions recognized in the income statement"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of additional other provisions made. [Refer: Other provisions]"
       }
      }
     },
     "auth_ref": [
      "r56"
     ]
    },
    "ubsag_AdjustmentsForCashCollateralOnDerivativeInstruments": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "AdjustmentsForCashCollateralOnDerivativeInstruments",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperatingActivities",
       "weight": 1.0,
       "order": 16.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Adjustments For Cash Collateral On Derivative Instruments",
        "terseLabel": "Cash collateral on derivative instruments",
        "documentation": "Adjustments for decrease (increase) in net cash collateral on derivative instruments to reconcile profit (loss) to net cash flow from (used in) operating activities."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_AdjustmentsForDecreaseIncreaseInBrokerageReceivablesAndBrokeragePayables": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "AdjustmentsForDecreaseIncreaseInBrokerageReceivablesAndBrokeragePayables",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperatingActivities",
       "weight": 1.0,
       "order": 20.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Adjustments For Decrease Increase In Brokerage Receivables And Brokerage Payables",
        "terseLabel": "Brokerage receivables and payables",
        "documentation": "Adjustments for decrease (increase) in brokerage receivables and payables to reconcile profit (loss) to net cash flow from (used in) operating activities."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_AdjustmentsForDecreaseIncreaseInFinancialAssetsAndFinancialLiabilitiesHeldForTradingAndDerivativeFinancialInstruments": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "AdjustmentsForDecreaseIncreaseInFinancialAssetsAndFinancialLiabilitiesHeldForTradingAndDerivativeFinancialInstruments",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperatingActivities",
       "weight": 1.0,
       "order": 19.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Adjustments For Decrease Increase In Financial Assets And Financial Liabilities Held For Trading And Derivative Financial Instruments",
        "terseLabel": "Financial assets and liabilities at fair value held for trading and derivative financial instruments",
        "documentation": "Adjustments for decrease (increase) in financial assets/liabilities held for trading and derivative financial instruments to reconcile profit (loss) to net cash flow from (used in) operating activities."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_AdjustmentsForDecreaseIncreaseInLoansAndAdvancesToCustomers": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "AdjustmentsForDecreaseIncreaseInLoansAndAdvancesToCustomers",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperatingActivities",
       "weight": 1.0,
       "order": 17.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Adjustments For Decrease Increase In Loans And Advances To Customers",
        "terseLabel": "Loans and advances to customers",
        "verboseLabel": "of which: Loans and advances to customers"
       }
      },
      "en": {
       "role": {
        "documentation": "Adjustments for decrease (increase) in loans and advances to customers to reconcile profit (loss) to net cash flow from (used in) operating activities. [Refer: Loans and advances to customers; Profit (loss)]"
       }
      }
     },
     "auth_ref": [
      "r259"
     ]
    },
    "ubsag_AdjustmentsForDecreaseIncreaseInOtherFinancialAssetsAndOtherFinancialLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "AdjustmentsForDecreaseIncreaseInOtherFinancialAssetsAndOtherFinancialLiabilities",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperatingActivities",
       "weight": 1.0,
       "order": 21.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Adjustments For Decrease Increase In Other Financial Assets And Other Financial Liabilities",
        "terseLabel": "Financial assets at fair value not held for trading and other financial assets and liabilities",
        "documentation": "Adjustments for decrease (increase) in other financial assets and liabilities to reconcile profit (loss) to net cash flow from (used in) operating activities."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_AdjustmentsForDecreaseIncreaseInReverseRepurchaseAgreementsAndCashCollateralOnSecuritiesBorrowed": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "AdjustmentsForDecreaseIncreaseInReverseRepurchaseAgreementsAndCashCollateralOnSecuritiesBorrowed",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperatingActivities",
       "weight": 1.0,
       "order": 15.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Adjustments For Decrease Increase In Reverse Repurchase Agreements And Cash Collateral On Securities Borrowed",
        "terseLabel": "Payables from securities financing transactions measured at amortized cost"
       }
      },
      "en": {
       "role": {
        "documentation": "Adjustments for decrease (increase) in reverse repurchase agreements and cash collateral on securities borrowed to reconcile profit (loss) to net cash flow from (used in) operating activities. [Refer: Reverse repurchase agreements and cash collateral on securities borrowed; Profit (loss)]"
       }
      }
     },
     "auth_ref": [
      "r259"
     ]
    },
    "ubsag_AdjustmentsForDecreaseIncreaseInReverseRepurchaseAgreementsAndCashCollateralOnSecuritiesLent": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "AdjustmentsForDecreaseIncreaseInReverseRepurchaseAgreementsAndCashCollateralOnSecuritiesLent",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperatingActivities",
       "weight": 1.0,
       "order": 14.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Adjustments For Decrease Increase In Reverse Repurchase Agreements And Cash Collateral On Securities Lent",
        "terseLabel": "Receivables from securities financing transactions measured at amortized cost",
        "documentation": "Adjustments for decrease (increase) in securities financing transactions to reconcile profit (loss) to net cash flow from (used in) operating activities."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_AdjustmentsForDeferredTaxExpense": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "AdjustmentsForDeferredTaxExpense",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperatingActivities",
       "weight": 1.0,
       "order": 8.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Adjustments For Deferred Tax Expense",
        "terseLabel": "Deferred tax expense / (benefit)"
       }
      },
      "en": {
       "role": {
        "documentation": "Adjustments for deferred tax expense to reconcile profit (loss) to net cash flow from (used in) operating activities. [Refer: Deferred tax expense (income); Profit (loss)]"
       }
      }
     },
     "auth_ref": [
      "r259"
     ]
    },
    "ifrs-full_AdjustmentsForDepreciationAndAmortisationExpenseAndImpairmentLossReversalOfImpairmentLossRecognisedInProfitOrLoss": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "AdjustmentsForDepreciationAndAmortisationExpenseAndImpairmentLossReversalOfImpairmentLossRecognisedInProfitOrLoss",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperatingActivities",
       "weight": 1.0,
       "order": 5.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Adjustments For Depreciation And Amortisation Expense And Impairment Loss Reversal Of Impairment Loss Recognised In Profit Or Loss",
        "terseLabel": "Depreciation, amortization and impairment of non-financial assets"
       }
      },
      "en": {
       "role": {
        "documentation": "Adjustments for depreciation and amortisation expense and impairment loss (reversal of impairment loss) to reconcile profit (loss) to net cash flow from (used in) operating activities. [Refer: Impairment loss; Depreciation and amortisation expense; Impairment loss (reversal of impairment loss) recognised in profit or loss; Profit (loss)]"
       }
      }
     },
     "auth_ref": [
      "r259"
     ]
    },
    "ubsag_AdjustmentsForDueFromToBanks": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "AdjustmentsForDueFromToBanks",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperatingActivities",
       "weight": 1.0,
       "order": 13.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Adjustments For Due From To Banks",
        "terseLabel": "Amounts due from banks and amounts due to banks",
        "documentation": "Adjustments for decrease (increase) in net due from/to banks to reconcile profit (loss) to net cash flow from (used in) operating activities."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_AdjustmentsForImpairmentLossReversalOfImpairmentLossRecognisedInProfitOrLossLoansAndAdvances": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "AdjustmentsForImpairmentLossReversalOfImpairmentLossRecognisedInProfitOrLossLoansAndAdvances",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperatingActivities",
       "weight": 1.0,
       "order": 6.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Adjustments For Impairment Loss Reversal Of Impairment Loss Recognised In Profit Or Loss Loans And Advances",
        "terseLabel": "Credit loss expense / (release)"
       }
      },
      "en": {
       "role": {
        "documentation": "Adjustments for impairment loss (reversal of impairment loss) on loans and advances recognised in profit or loss to reconcile profit (loss) to net cash flow from (used in) operating activities. [Refer: Adjustments for impairment loss (reversal of impairment loss) recognised in profit or loss]"
       }
      }
     },
     "auth_ref": [
      "r259"
     ]
    },
    "ifrs-full_AdjustmentsForIncreaseDecreaseInDepositsFromCustomers": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "AdjustmentsForIncreaseDecreaseInDepositsFromCustomers",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperatingActivities",
       "weight": 1.0,
       "order": 18.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Adjustments For Increase Decrease In Deposits From Customers",
        "terseLabel": "Customer deposits"
       }
      },
      "en": {
       "role": {
        "documentation": "Adjustments for increase (decrease) in deposits from customers to reconcile profit (loss) to net cash flow from (used in) operating activities. [Refer: Deposits from customers; Profit (loss)]"
       }
      }
     },
     "auth_ref": [
      "r259"
     ]
    },
    "ifrs-full_AdjustmentsForUndistributedProfitsOfAssociates": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "AdjustmentsForUndistributedProfitsOfAssociates",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperatingActivities",
       "weight": -1.0,
       "order": 7.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Share of net (profit) / loss of associates and joint ventures and impairment related to associates",
        "label": "Adjustments For Undistributed Profits Of Associates"
       }
      },
      "en": {
       "role": {
        "documentation": "Adjustments for undistributed profits of associates to reconcile profit (loss) to net cash flow from (used in) operating activities. [Refer: Associates [member]; Profit (loss)]"
       }
      }
     },
     "auth_ref": [
      "r258"
     ]
    },
    "ifrs-full_AggregateDifferenceBetweenFairValueAtInitialRecognitionAndAmountDeterminedUsingValuationTechniqueYetToBeRecognised": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "AggregateDifferenceBetweenFairValueAtInitialRecognitionAndAmountDeterminedUsingValuationTechniqueYetToBeRecognised",
     "presentation": [
      "http://www.ubsag.com/role/FVMValuationAdjustmentsDeferredDay1PLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Aggregate Difference Between Fair Value At Initial Recognition And Amount Determined Using Valuation Technique Yet To Be Recognised",
        "periodStartLabel": "Reserve balance at the beginning of the period",
        "periodEndLabel": "Reserve balance at the end of the period"
       }
      },
      "en": {
       "role": {
        "documentation": "The aggregate difference between the fair value at initial recognition and the transaction price for financial instruments that is yet to be recognised in profit or loss. [Refer: Financial instruments, class [member]]"
       }
      }
     },
     "auth_ref": [
      "r144"
     ]
    },
    "ifrs-full_AggregatedMeasurementMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "AggregatedMeasurementMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMFinancialInstrumentsNotMeasuredAtFairValueAssetsDetail",
      "http://www.ubsag.com/role/FVMFinancialInstrumentsNotMeasuredAtFairValueLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Aggregated Measurement [Member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for all types of measurement. It also represents the standard value for the 'Measurement' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r65",
      "r69",
      "r97"
     ]
    },
    "ifrs-full_AggregatedTimeBandsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "AggregatedTimeBandsMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementComparisonOfShockFactorsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Aggregated Time Bands [Member]",
        "terseLabel": "Total"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for aggregated time bands. It also represents the standard value for the 'Maturity' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r19",
      "r113",
      "r116",
      "r117",
      "r118",
      "r119",
      "r120",
      "r127",
      "r142",
      "r204",
      "r231",
      "r233"
     ]
    },
    "ubsag_AllBondCurrenciesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "AllBondCurrenciesMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementComparisonOfShockFactorsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "This member stands for all bond currencies.",
        "label": "All Bond Currencies [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_AllCurrenciesExchangeRateMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "AllCurrenciesExchangeRateMember",
     "presentation": [
      "http://www.ubsag.com/role/BasisOfAccountingCurrencyTranslationRatesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "All Currencies Exchange Rate [Member]",
        "documentation": "This member stands for all currency exchange rates."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_AllLevelsOfFairValueHierarchyMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "AllLevelsOfFairValueHierarchyMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail",
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail",
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "All Levels Of Fair Value Hierarchy [Member]",
        "terseLabel": "Total"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for all levels of the fair value hierarchy. It also represents the standard value for the 'Levels of fair value hierarchy' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r44",
      "r98"
     ]
    },
    "ifrs-full_AllowanceForCreditLossesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "AllowanceForCreditLossesMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementECLrelevantBalanceSheetAndOffbalanceSheetPositionsIncludingECLAllowancesAndProvisionsNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Allowance For Credit Losses [Member]",
        "terseLabel": "Allowance for expected credit loss"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for an allowance account used to record impairments to financial assets due to credit losses."
       }
      }
     },
     "auth_ref": [
      "r253"
     ]
    },
    "ubsag_AllowanceForCreditLossesOnFinancialAssetsAndProvisionsForExpectedCreditLossesOnLoanCommitmentsAndFinancialGuaranteeContracts": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "AllowanceForCreditLossesOnFinancialAssetsAndProvisionsForExpectedCreditLossesOnLoanCommitmentsAndFinancialGuaranteeContracts",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementChangesToECLModelsScenariosScenarioWeightsAndPostmodelAdjustmentsNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Allowance For Credit Losses On Financial Assets And Provisions For Expected Credit Losses On Loan Commitments And Financial Guarantee Contracts",
        "terseLabel": "Total ECL allowances and provisions",
        "verboseLabel": "Total allowances and provisions",
        "documentation": "The total amount of allowances for impairments to financial assets due to credit losses and provisions for expected credit losses on loan commitments and financial guarantee contracts."
       }
      }
     },
     "auth_ref": []
    },
    "dei_AmendmentFlag": {
     "xbrltype": "booleanItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2023",
     "localname": "AmendmentFlag",
     "presentation": [
      "http://www.ubsag.com/role/DocumentAndEntityInformation"
     ],
     "lang": {
      "en-us": {
       "role": {
        "terseLabel": "Amendment flag",
        "label": "Amendment Flag",
        "documentation": "Boolean flag that is true when the XBRL content amends previously-filed or accepted submission."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_AmountDueUnderUnitLinkedInvestmentContracts": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "AmountDueUnderUnitLinkedInvestmentContracts",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/OtherFinancialLiabilitiesDesignatedAtFairValueDetail": {
       "parentTag": "ubsag_OtherFinancialLiabilitiesAtFairValueThroughProfitOrLossDesignatedAsUponInitialRecognition",
       "weight": 1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherFinancialLiabilitiesDesignatedAtFairValueDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "terseLabel": "Financial liabilities related to unit-linked investment contracts",
        "documentation": "The amount of financial liabilities related to unit-linked investment contracts.",
        "label": "Amount Due Under Unit-linked Investment Contracts"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_AmountDueUnderUnitLinkedInvestmentContractsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "AmountDueUnderUnitLinkedInvestmentContractsMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Amount Due Under Unit Linked Investment Contracts [Member]",
        "terseLabel": "Amounts due under unit-linked investment contracts",
        "documentation": "This member relates to amounts related to unit-linked investment contracts.",
        "verboseLabel": "Financial liabilities related to unit-linked investment contracts"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_AmountInDispute": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "AmountInDispute",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Amount In Dispute",
        "terseLabel": "Amount in dispute",
        "documentation": "The amount that is disputed."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_AmountsSubjectToEnforceableMasterNettingArrangementOrSimilarAgreementNotSetOffAgainstFinancialAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "AmountsSubjectToEnforceableMasterNettingArrangementOrSimilarAgreementNotSetOffAgainstFinancialAssets",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/OffsettingFinancialAssetsDetail": {
       "parentTag": "ubsag_AssetsAfterConsiderationOfNettingPotential",
       "weight": -1.0,
       "order": 3.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OffsettingFinancialAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Amounts Subject To Enforceable Master Netting Arrangement Or Similar Agreement Not Set Off Against Financial Assets",
        "terseLabel": "Further netting potential not recognized on the balance sheet",
        "negatedTotalLabel": "Further netting potential not recognized on the balance sheet"
       }
      },
      "en": {
       "role": {
        "documentation": "The amounts that are subject to an enforceable master netting arrangement or similar agreement and that are not set off against financial assets. [Refer: Financial assets]"
       }
      }
     },
     "auth_ref": [
      "r136"
     ]
    },
    "ifrs-full_AmountsSubjectToEnforceableMasterNettingArrangementOrSimilarAgreementNotSetOffAgainstFinancialLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "AmountsSubjectToEnforceableMasterNettingArrangementOrSimilarAgreementNotSetOffAgainstFinancialLiabilities",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/OffsettingFinancialLiabilitiesDetail": {
       "parentTag": "ubsag_LiabilitiesAfterConsiderationOfNettingPotential",
       "weight": -1.0,
       "order": 3.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OffsettingFinancialLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Amounts Subject To Enforceable Master Netting Arrangement Or Similar Agreement Not Set Off Against Financial Liabilities",
        "negatedTotalLabel": "Further netting potential not recognized on the balance sheet"
       }
      },
      "en": {
       "role": {
        "documentation": "The amounts that are subject to an enforceable master netting arrangement or similar agreement and that are not set off against financial liabilities. [Refer: Financial liabilities]"
       }
      }
     },
     "auth_ref": [
      "r136"
     ]
    },
    "ubsag_AssetBackedSecuritiesCorporationHomeEquityLoanTrustMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "AssetBackedSecuritiesCorporationHomeEquityLoanTrustMember",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Asset Backed Securities Corporation Home Equity Loan Trust [Member]",
        "terseLabel": "Mortgage-related matters | Action brought by Asset Backed Securities Corporation Home Equity Loan Trust, Series 2006-HE7",
        "documentation": "This member refers to action brought by Asset Backed Securities Corporation Home Equity Loan Trust, Series 2006-HE7."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_AssetBackedSecuritiesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "AssetBackedSecuritiesMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail",
      "http://www.ubsag.com/role/FVMLevel3InstrumentsSensitivityToChangesInUnobservableInputAssumptionsDetail",
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Asset Backed Securities [Member]",
        "terseLabel": "Asset-backed securities",
        "verboseLabel": "Financial assets and liabilities at fair value held for trading, Financial assets at fair value not held for trading: Asset-backed securities",
        "documentation": "This member relates to asset backed securities."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_Assets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "Assets",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/SegmentReportingDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Assets",
        "totalLabel": "Total assets",
        "terseLabel": "Total assets measured at fair value",
        "periodEndLabel": "Balance as of 31 December",
        "positiveTerseLabel": "Total assets recognized on the balance sheet",
        "verboseLabel": "Total assets",
        "periodStartLabel": "Balance as of 31 December"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of a present economic resource controlled by the entity as a result of past events. Economic resource is a right that has the potential to produce economic benefits."
       }
      }
     },
     "auth_ref": [
      "r16",
      "r97",
      "r98",
      "r103",
      "r176",
      "r180"
     ]
    },
    "ifrs-full_AssetsAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "AssetsAbstract",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail",
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Assets [Abstract]",
        "terseLabel": "Assets",
        "verboseLabel": "Total assets"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_AssetsAfterConsiderationOfNettingPotential": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "AssetsAfterConsiderationOfNettingPotential",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/OffsettingFinancialAssetsDetail": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OffsettingFinancialAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Assets After Consideration Of Netting Potential",
        "totalLabel": "Assets, after consideration of further netting potential",
        "documentation": "The amount of assets after consideration of netting potential."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_AssetsAtFairValueTransferred": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "AssetsAtFairValueTransferred",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Assets At Fair Value Transferred",
        "terseLabel": "Effect from a business combination",
        "documentation": "The amount of assets measured at fair value transferred in a business combination."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_AssetsHeldAsCollateralPermittedToBeSoldOrRepledgedAtFairValue": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "AssetsHeldAsCollateralPermittedToBeSoldOrRepledgedAtFairValue",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Assets Held As Collateral Permitted To Be Sold Or Repledged At Fair Value",
        "terseLabel": "of which: assets pledged as collateral that may be sold or repledged by counterparties",
        "totalLabel": "Fair value of assets received which can be sold or repledged"
       }
      },
      "en": {
       "role": {
        "documentation": "The fair value of collateral held that is permitted to be sold or repledged in the absence of default by the owner of the collateral. [Refer: At fair value [member]]"
       }
      }
     },
     "auth_ref": [
      "r138"
     ]
    },
    "ubsag_AssetsMeasuredAtFairValue": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "AssetsMeasuredAtFairValue",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Assets Measured At Fair Value",
        "totalLabel": "Total assets measured at fair value",
        "documentation": "The amount of financial and non-financial assets measured at fair value."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_AssetsTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "AssetsTransferredAsOfTheMergerDate",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Assets Transferred As Of The Merger Date",
        "terseLabel": "Total assets",
        "documentation": "The amount of a present economic resource controlled by the entity as a result of past events. Economic resource is a right that has the potential to produce economic benefits."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_AuctionRateSecuritiesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "AuctionRateSecuritiesMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail",
      "http://www.ubsag.com/role/FVMLevel3InstrumentsSensitivityToChangesInUnobservableInputAssumptionsDetail",
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Auction Rate Securities [Member]",
        "terseLabel": "Auction rate securities",
        "documentation": "This member relates to auction rate securities.",
        "verboseLabel": "Financial assets and liabilities at fair value held for trading, Financial assets at fair value not held for trading: Auction rate securities"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_AverageForeignExchangeRate": {
     "xbrltype": "decimalItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "AverageForeignExchangeRate",
     "presentation": [
      "http://www.ubsag.com/role/BasisOfAccountingCurrencyTranslationRatesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Average Foreign Exchange Rate",
        "terseLabel": "Average rate"
       }
      },
      "en": {
       "role": {
        "documentation": "The average exchange rate used by the entity. Exchange rate is the ratio of exchange for two currencies."
       }
      }
     },
     "auth_ref": [
      "r247"
     ]
    },
    "ubsag_BailDeposit": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "BailDeposit",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/OtherNonfinancialAssetsDetail": {
       "parentTag": "ifrs-full_OtherNonfinancialAssets",
       "weight": 1.0,
       "order": 3.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherNonfinancialAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Bail Deposit",
        "documentation": "The amount of bail deposits relating to inquiries regarding cross-border wealth management businesses.",
        "terseLabel": "Deposits and collateral provided in connection with litigation, regulatory and similar matters"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_BailOrdered": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "BailOrdered",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Bail Ordered",
        "terseLabel": "Bail (\"caution\") ordered to be paid",
        "documentation": "The amount of bail (\"caution\") ordered to be paid."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_BailOrderedConfiscationFrenchCourtOfAppeal": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "BailOrderedConfiscationFrenchCourtOfAppeal",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Bail Ordered Confiscation French Court Of Appeal",
        "terseLabel": "Bail (\"caution\") ordered to be confiscated, verdict of the French Court of Appeal",
        "documentation": "The amount of bail (\"caution\") ordered to be confiscated in the verdict of the French Court of Appeal."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_BalanceSheetLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "BalanceSheetLineItems",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Balance Sheet [Line Items]",
        "terseLabel": "Balance sheet",
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with domain members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_BaselineScenarioMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "BaselineScenarioMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementComparisonOfShockFactorsDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementEconomicScenariosAndWeightsAppliedDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Baseline Scenario [Member]",
        "terseLabel": "Baseline",
        "documentation": "This member stands for baseline economic scenarios used in the calculation of expected credit losses."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_BasicEarningsLossPerShare": {
     "xbrltype": "perShareItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "BasicEarningsLossPerShare",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Basic Earnings Loss Per Share",
        "terseLabel": "Basic"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of profit (loss) attributable to ordinary equity holders of the parent entity (the numerator) divided by the weighted average number of ordinary shares outstanding during the period (the denominator)."
       }
      }
     },
     "auth_ref": [
      "r52",
      "r53"
     ]
    },
    "ubsag_BermudaCivilLawsuitsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "BermudaCivilLawsuitsMember",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Bermuda Civil Lawsuits [Member]",
        "terseLabel": "Customer account matters | Bermuda civil lawsuits",
        "documentation": "This member refers to a civil lawsuit brought in Bermuda."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_BermudaStatutoryRate": {
     "xbrltype": "percentItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "BermudaStatutoryRate",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Bermuda Statutory Rate",
        "terseLabel": "Bermuda statutory rate",
        "documentation": "The statutory rate in Bermuda."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_BondCurrencyAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "BondCurrencyAxis",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementComparisonOfShockFactorsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Bond Currency Axis [Axis]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_BondCurrencyCHFMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "BondCurrencyCHFMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementComparisonOfShockFactorsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Bond Currency CHF [Member]",
        "terseLabel": "CHF",
        "documentation": "This member stands for bond currency CHF."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_BondCurrencyEURMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "BondCurrencyEURMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementComparisonOfShockFactorsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "This member stands for bond currency EUR.",
        "label": "Bond Currency EUR [Member]",
        "terseLabel": "EUR"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_BondCurrencyUSDMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "BondCurrencyUSDMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementComparisonOfShockFactorsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Bond Currency USD [Member]",
        "terseLabel": "USD",
        "documentation": "This member stands for bond currency USD."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_BondPriceEquivalentMeasurementInputMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "BondPriceEquivalentMeasurementInputMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Bond Price Equivalent Measurement Input [Member]",
        "terseLabel": "Bond price equivalent (% of par)",
        "documentation": "This member stands for bond price equivalent used as a significant Level 3 unobservable input."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_BondsIssuedByCreditSuisseAGStandalioneSeniorFixedRateWithMaturityGreaterThanOneYear": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "BondsIssuedByCreditSuisseAGStandalioneSeniorFixedRateWithMaturityGreaterThanOneYear",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Bonds Issued By Credit Suisse AG Standalione Senior Fixed Rate With Maturity Greater Than One Year",
        "terseLabel": "of which: issued by Credit Suisse AG standalone with original maturity greater than one year",
        "documentation": "The amount of senior fixed-rate bonds issued by Credit Suisse AG standalone, which have maturity greater than one year."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_BondsIssuedCovered": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "BondsIssuedCovered",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostDetail": {
       "parentTag": "ifrs-full_NoncurrentDebtInstrumentsIssued",
       "weight": 1.0,
       "order": 6.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The amount of covered bonds issued by the entity.",
        "terseLabel": "Covered bonds",
        "label": "Bonds Issued Covered"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_BondsIssuedCoveredSecuredPortion": {
     "xbrltype": "percentItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "BondsIssuedCoveredSecuredPortion",
     "presentation": [
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Bonds Issued Covered Secured Portion",
        "terseLabel": "Secured portion of Covered bonds",
        "documentation": "The percentage for secured portion of Covered bonds."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_BondsIssuedSeniorFixedRateWithMaturityGreaterThanOneYear": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "BondsIssuedSeniorFixedRateWithMaturityGreaterThanOneYear",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Bonds Issued Senior Fixed Rate With Maturity Greater Than One Year",
        "terseLabel": "of which: issued by UBS AG standalone with original maturity greater than one year",
        "documentation": "The amount of senior fixed-rate bonds issued by the entity, which have maturity greater than one year."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_BondsIssuedSeniorUnsecured": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "BondsIssuedSeniorUnsecured",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostDetail": {
       "parentTag": "ifrs-full_NoncurrentDebtInstrumentsIssued",
       "weight": 1.0,
       "order": 3.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The amount of senior unsecured bonds other than TLAC issued by the entity.",
        "terseLabel": "Senior unsecured debt",
        "label": "Bonds Issued Senior Unsecured"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_BorrowingsByTypeAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "BorrowingsByTypeAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Borrowings By Type [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_BottomOfRangeMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "BottomOfRangeMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail",
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Bottom Of Range [Member]",
        "terseLabel": "low",
        "verboseLabel": "Minimum"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for the bottom of a range."
       }
      }
     },
     "auth_ref": [
      "r108",
      "r120",
      "r128",
      "r216",
      "r218",
      "r264"
     ]
    },
    "ifrs-full_BrokerageFeeIncome": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "BrokerageFeeIncome",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail": {
       "parentTag": "ifrs-full_FeeAndCommissionIncome",
       "weight": 1.0,
       "order": 4.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Brokerage Fee Income",
        "terseLabel": "Brokerage fees"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of income recognised for brokerage fees charged by the entity."
       }
      }
     },
     "auth_ref": [
      "r247"
     ]
    },
    "ubsag_BrokeragePayablesMeasuredAtFairValueThroughProfitOrLoss": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "BrokeragePayablesMeasuredAtFairValueThroughProfitOrLoss",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail": {
       "parentTag": "ifrs-full_FinancialLiabilitiesAtFairValueThroughProfitOrLoss",
       "weight": 1.0,
       "order": 4.0
      },
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_FinancialLiabilitiesAtFairValueThroughProfitOrLoss",
       "weight": 1.0,
       "order": 34.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Brokerage Payables Measured At Fair Value Through Profit Or Loss",
        "terseLabel": "Brokerage payables designated at fair value",
        "documentation": "The amount of brokerage payables designated at fair value through profit or loss."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_BrokeragePayablesMeasuredAtFairValueThroughProfitOrLossTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "BrokeragePayablesMeasuredAtFairValueThroughProfitOrLossTransferredAsOfTheMergerDate",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Brokerage Payables Measured At Fair Value Through Profit Or Loss Transferred As Of The Merger Date",
        "terseLabel": "Brokerage payables designated at fair value",
        "documentation": "The amount of brokerage payables designated at fair value through profit or loss."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_BrokerageReceivablesMeasuredAtFairValueThroughProfitOrLoss": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "BrokerageReceivablesMeasuredAtFairValueThroughProfitOrLoss",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail": {
       "parentTag": "ubsag_AssetsMeasuredAtFairValue",
       "weight": 1.0,
       "order": 4.0
      },
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_FinancialAssetsAtFairValueThroughProfitOrLoss",
       "weight": 1.0,
       "order": 13.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Brokerage Receivables Measured At Fair Value Through Profit Or Loss",
        "terseLabel": "Brokerage receivables",
        "documentation": "The amount of brokerage receivables mandatorily measured at fair value through profit or loss."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_BrokerageReceivablesMeasuredAtFairValueThroughProfitOrLossTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "BrokerageReceivablesMeasuredAtFairValueThroughProfitOrLossTransferredAsOfTheMergerDate",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Brokerage Receivables Measured At Fair Value Through Profit Or Loss Transferred As Of The Merger Date",
        "terseLabel": "Brokerage receivables",
        "documentation": "The amount of brokerage receivables mandatorily measured at fair value through profit or loss."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_BulgarianFormerClientsMatterMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "BulgarianFormerClientsMatterMember",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Bulgarian Former Clients Matter [Member]",
        "terseLabel": "Bulgarian former client matter",
        "documentation": "This member refers to a historical relationship with former clients alleged to have laundered funds through Credit Suisse AG accounts."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_BusinessCombinationsUnderCommonControlAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "BusinessCombinationsUnderCommonControlAxis",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail",
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity",
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquityParenthetical",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail",
      "http://www.ubsag.com/role/FVMValuationAdjustmentsDeferredDay1PLDetail",
      "http://www.ubsag.com/role/SegmentReportingNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Business Combinations Under Common Control [Axis]"
       }
      }
     },
     "auth_ref": []
    },
    "country_CH": {
     "xbrltype": "domainItemType",
     "nsuri": "http://xbrl.sec.gov/country/2023",
     "localname": "CH",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementComparisonOfShockFactorsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Switzerland [Member]",
        "terseLabel": "Switzerland"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_CHFCurrencyExchangeRateMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CHFCurrencyExchangeRateMember",
     "presentation": [
      "http://www.ubsag.com/role/BasisOfAccountingCurrencyTranslationRatesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "This member stands for currency translation rate of 1 CHF to the presentation currency.",
        "label": "CHF Currency Exchange Rate [Member]",
        "terseLabel": "1 CHF"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_CancellationOfTreasuryShares": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "CancellationOfTreasuryShares",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cancellation Of Treasury Shares",
        "terseLabel": "Cancelation of treasury shares related to the share repurchase program"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of treasury stock cancelled during the period. [Refer: Treasury shares]"
       }
      }
     },
     "auth_ref": [
      "r246"
     ]
    },
    "ifrs-full_CarryingAmountAccumulatedDepreciationAmortisationAndImpairmentAndGrossCarryingAmountAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "CarryingAmountAccumulatedDepreciationAmortisationAndImpairmentAndGrossCarryingAmountAxis",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementECLrelevantBalanceSheetAndOffbalanceSheetPositionsIncludingECLAllowancesAndProvisionsNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Carrying Amount Accumulated Depreciation Amortisation And Impairment And Gross Carrying Amount [Axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r42",
      "r43",
      "r61",
      "r62",
      "r66",
      "r67",
      "r68",
      "r69",
      "r70",
      "r129",
      "r151",
      "r152"
     ]
    },
    "ifrs-full_CarryingAmountMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "CarryingAmountMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementECLrelevantBalanceSheetAndOffbalanceSheetPositionsIncludingECLAllowancesAndProvisionsNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Carrying Amount [Member]",
        "terseLabel": "Net carrying amount",
        "verboseLabel": "Net credit impaired financial instruments"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for the amount at which an asset is recognised in the statement of financial position (after deducting any accumulated depreciation or amortisation and accumulated impairment losses). It also represents the standard value for the 'Carrying amount, accumulated depreciation, amortisation and impairment and gross carrying amount' axis if no other member is used. [Refer: Depreciation and amortisation expense; Impairment loss]"
       }
      }
     },
     "auth_ref": [
      "r43",
      "r62",
      "r66",
      "r68",
      "r69",
      "r129",
      "r151",
      "r152"
     ]
    },
    "ubsag_CarryingAmountOfFinancialAssetsReclassifiedOutOfFairValueThroughOtherComprehensiveIncomeCategoryIntoAmortisedCostCategory": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CarryingAmountOfFinancialAssetsReclassifiedOutOfFairValueThroughOtherComprehensiveIncomeCategoryIntoAmortisedCostCategory",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/ReclassificationOfFinancialAssetsNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Carrying Amount Of Financial Assets Reclassified Out Of Fair Value Through Other Comprehensive Income Category Into Amortised Cost Category",
        "terseLabel": "Carrying amount of financial assets reclassified out of fair value through other comprehensive income category into amortised cost category",
        "documentation": "The carrying amount of financial assets reclassified out of fair value through other comprehensive income category into amortised cost category."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_CashAndBankBalancesAtCentralBanks": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "CashAndBankBalancesAtCentralBanks",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_FinancialAssetsAtAmortisedCost",
       "weight": 1.0,
       "order": 3.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/FVMFinancialInstrumentsNotMeasuredAtFairValueAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cash And Bank Balances At Central Banks",
        "terseLabel": "Cash and balances at central banks",
        "verboseLabel": "of which: cash and balances with central banks"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of cash and bank balances held at central banks."
       }
      }
     },
     "auth_ref": [
      "r249"
     ]
    },
    "ubsag_CashAndBankBalancesAtCentralBanksClassifiedAsCashEquivalents": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CashAndBankBalancesAtCentralBanksClassifiedAsCashEquivalents",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cash And Bank Balances At Central Banks Classified As Cash Equivalents",
        "terseLabel": "Cash and balances at central banks classified as cash equivalents",
        "verboseLabel": "of which: cash and balances at central banks",
        "documentation": "A classification of cash equivalents representing cash and bank balances at central banks."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_CashAndBankBalancesAtCentralBanksMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CashAndBankBalancesAtCentralBanksMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "terseLabel": "Cash and balances at central banks",
        "label": "Cash And Bank Balances At Central Banks [Member]",
        "documentation": "This member relates to cash and balances with central banks."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_CashAndBankBalancesAtCentralBanksTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CashAndBankBalancesAtCentralBanksTransferredAsOfTheMergerDate",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cash And Bank Balances At Central Banks Transferred As Of The Merger Date",
        "terseLabel": "Cash and balances at central banks",
        "documentation": "The amount of cash and bank balances held at central banks."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_CashAndCashEquivalents": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "CashAndCashEquivalents",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cash And Cash Equivalents",
        "periodStartLabel": "Cash and cash equivalents at the beginning of the period",
        "periodEndLabel": "Cash and cash equivalents at the end of the period",
        "verboseLabel": "Cash and cash equivalents at the beginning of the year"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of cash on hand and demand deposits, along with short-term, highly liquid investments that are readily convertible to known amounts of cash and that are subject to an insignificant risk of changes in value. [Refer: Cash; Cash equivalents]"
       }
      }
     },
     "auth_ref": [
      "r10",
      "r80",
      "r94"
     ]
    },
    "ifrs-full_CashAndCashEquivalentsAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "CashAndCashEquivalentsAbstract",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cash And Cash Equivalents Abstract",
        "terseLabel": "Total cash flow"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_CashAndCashEquivalentsInSubsidiaryOrBusinessesAcquiredOrDisposed2013": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "CashAndCashEquivalentsInSubsidiaryOrBusinessesAcquiredOrDisposed2013",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInInvestingActivities",
       "weight": 1.0,
       "order": 26.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cash And Cash Equivalents In Subsidiary Or Businesses Acquired Or Disposed",
        "terseLabel": "Cash and cash equivalents obtained due to the merger of UBS AG and Credit Suisse AG"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of cash and cash equivalents in subsidiaries or other businesses over which control is obtained or lost. [Refer: Subsidiaries [member]; Cash and cash equivalents]"
       }
      }
     },
     "auth_ref": [
      "r79"
     ]
    },
    "ubsag_CashCollateralPayablesOnDerivativeInstruments": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CashCollateralPayablesOnDerivativeInstruments",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_FinancialLiabilitiesAtAmortisedCost",
       "weight": 1.0,
       "order": 26.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/FVMFinancialInstrumentsNotMeasuredAtFairValueLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cash Collateral Payables On Derivative Instruments",
        "terseLabel": "Cash collateral payables on derivative instruments",
        "documentation": "The amount of exchange-traded derivative liabilities and certain OTC derivative liabilities cleared through central clearing counterparties which are either considered to be daily settled or qualify for netting."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_CashCollateralPayablesOnDerivativeInstrumentsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CashCollateralPayablesOnDerivativeInstrumentsMember",
     "presentation": [
      "http://www.ubsag.com/role/OffsettingFinancialLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cash Collateral Payables On Derivative Instruments [Member]",
        "terseLabel": "Cash collateral payables on derivative instruments",
        "documentation": "This member relates to cash collateral payables on derivative instruments."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_CashCollateralPayablesOnDerivativeInstrumentsTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CashCollateralPayablesOnDerivativeInstrumentsTransferredAsOfTheMergerDate",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cash Collateral Payables On Derivative Instruments Transferred As Of The Merger Date",
        "terseLabel": "Cash collateral payables on derivative instruments",
        "documentation": "The amount of exchange-traded derivative liabilities and certain OTC derivative liabilities cleared through central clearing counterparties which are either considered to be daily settled or qualify for netting."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_CashCollateralPledgedSubjectToEnforceableMasterNettingArrangementOrSimilarAgreementNotSetOffAgainstFinancialLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "CashCollateralPledgedSubjectToEnforceableMasterNettingArrangementOrSimilarAgreementNotSetOffAgainstFinancialLiabilities",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/OffsettingFinancialLiabilitiesDetail": {
       "parentTag": "ifrs-full_AmountsSubjectToEnforceableMasterNettingArrangementOrSimilarAgreementNotSetOffAgainstFinancialLiabilities",
       "weight": 1.0,
       "order": 5.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OffsettingFinancialLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cash Collateral Pledged Subject To Enforceable Master Netting Arrangement Or Similar Agreement Not Set Off Against Financial Liabilities",
        "negatedLabel": "of which: netting with collateral pledged"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of cash collateral pledged that is subject to an enforceable master netting arrangement or similar agreement and that is not set off against financial liabilities. [Refer: Financial liabilities]"
       }
      }
     },
     "auth_ref": [
      "r225",
      "r241"
     ]
    },
    "ubsag_CashCollateralReceivablesOnDerivativeInstruments": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CashCollateralReceivablesOnDerivativeInstruments",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_FinancialAssetsAtAmortisedCost",
       "weight": 1.0,
       "order": 6.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/FVMFinancialInstrumentsNotMeasuredAtFairValueAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cash Collateral Receivables On Derivative Instruments",
        "terseLabel": "Cash collateral receivables on derivative instruments",
        "documentation": "The amount of exchange-traded derivative assets and certain OTC derivative assets cleared through central clearing counterparties which are either considered to be daily settled or qualify for netting.",
        "verboseLabel": "Cash collateral on securities borrowed (newly included in Receivables from securities financing transactions)"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_CashCollateralReceivablesOnDerivativeInstrumentsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CashCollateralReceivablesOnDerivativeInstrumentsMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail",
      "http://www.ubsag.com/role/OffsettingFinancialAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "terseLabel": "Cash collateral receivables on derivative instruments",
        "documentation": "This member relates to cash collateral receivables on derivative instruments.",
        "label": "Cash Collateral Receivables On Derivative Instruments [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_CashCollateralReceivablesOnDerivativeInstrumentsTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CashCollateralReceivablesOnDerivativeInstrumentsTransferredAsOfTheMergerDate",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cash Collateral Receivables On Derivative Instruments Transferred As Of The Merger Date",
        "terseLabel": "Cash collateral receivables on derivative instruments",
        "documentation": "The amount of exchange-traded derivative assets and certain OTC derivative assets cleared through central clearing counterparties which are either considered to be daily settled or qualify for netting."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_CashCollateralReceivedSubjectToEnforceableMasterNettingArrangementOrSimilarAgreementNotSetOffAgainstFinancialAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "CashCollateralReceivedSubjectToEnforceableMasterNettingArrangementOrSimilarAgreementNotSetOffAgainstFinancialAssets",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/OffsettingFinancialAssetsDetail": {
       "parentTag": "ifrs-full_AmountsSubjectToEnforceableMasterNettingArrangementOrSimilarAgreementNotSetOffAgainstFinancialAssets",
       "weight": 1.0,
       "order": 5.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OffsettingFinancialAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cash Collateral Received Subject To Enforceable Master Netting Arrangement Or Similar Agreement Not Set Off Against Financial Assets",
        "negatedLabel": "of which: netting with collateral received"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of cash collateral received that is subject to an enforceable master netting arrangement or similar agreement and that is not set off against financial assets. [Refer: Financial assets]"
       }
      }
     },
     "auth_ref": [
      "r225",
      "r241"
     ]
    },
    "ifrs-full_CashFlowHedgesAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "CashFlowHedgesAbstract",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cash Flow Hedges [Abstract]",
        "terseLabel": "Cash flow hedges",
        "verboseLabel": "Cash flow hedges of interest rate risk"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_CashFlowsFromUsedInFinancingActivities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "CashFlowsFromUsedInFinancingActivities",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_IncreaseDecreaseInCashAndCashEquivalentsBeforeEffectOfExchangeRateChanges",
       "weight": 1.0,
       "order": 44.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cash Flows From Used In Financing Activities",
        "totalLabel": "Net cash flow from / (used in) financing activities",
        "terseLabel": "Net cash flow from / (used in) financing activities"
       }
      },
      "en": {
       "role": {
        "documentation": "The cash flows from (used in) financing activities, which are activities that result in changes in the size and composition of the contributed equity and borrowings of the entity."
       }
      }
     },
     "auth_ref": [
      "r71",
      "r81"
     ]
    },
    "ifrs-full_CashFlowsFromUsedInFinancingActivitiesAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "CashFlowsFromUsedInFinancingActivitiesAbstract",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cash Flows From Used In Financing Activities [Abstract]",
        "terseLabel": "Cash flow from / (used in) financing activities"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_CashFlowsFromUsedInInvestingActivities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "CashFlowsFromUsedInInvestingActivities",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_IncreaseDecreaseInCashAndCashEquivalentsBeforeEffectOfExchangeRateChanges",
       "weight": 1.0,
       "order": 34.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cash Flows From Used In Investing Activities",
        "totalLabel": "Net cash flow from / (used in) investing activities",
        "terseLabel": "Net cash flow from / (used in) investing activities"
       }
      },
      "en": {
       "role": {
        "documentation": "The cash flows from (used in) investing activities, which are the acquisition and disposal of long-term assets and other investments not included in cash equivalents."
       }
      }
     },
     "auth_ref": [
      "r71",
      "r81"
     ]
    },
    "ifrs-full_CashFlowsFromUsedInInvestingActivitiesAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "CashFlowsFromUsedInInvestingActivitiesAbstract",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cash Flows From Used In Investing Activities [Abstract]",
        "terseLabel": "Cash flow from / (used in) investing activities"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_CashFlowsFromUsedInOperatingActivities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "CashFlowsFromUsedInOperatingActivities",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_IncreaseDecreaseInCashAndCashEquivalentsBeforeEffectOfExchangeRateChanges",
       "weight": 1.0,
       "order": 24.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows",
      "http://www.ubsag.com/role/SupplementalGuarantorConsolidatedStatementOfCashFlowsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cash Flows From Used In Operating Activities",
        "totalLabel": "Net cash flow from / (used in) operating activities",
        "terseLabel": "Net cash flow from / (used in) operating activities"
       }
      },
      "en": {
       "role": {
        "documentation": "The cash flows from (used in) operating activities, which are the principal revenue-producing activities of the entity and other activities that are not investing or financing activities. [Refer: Revenue]"
       }
      }
     },
     "auth_ref": [
      "r71",
      "r81"
     ]
    },
    "ifrs-full_CashFlowsFromUsedInOperatingActivitiesAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "CashFlowsFromUsedInOperatingActivitiesAbstract",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cash Flows From Used In Operating Activities Abstract",
        "terseLabel": "Cash flow from / (used in) operating activities"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_CashFlowsFromUsedInOperatingActivitiesIncludesAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CashFlowsFromUsedInOperatingActivitiesIncludesAbstract",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cash Flows From Used In Operating Activities Includes Abstract",
        "terseLabel": "Net cash flow from / (used in) operating activities includes:"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_CashReceiptsFromTheSaleOfLoansAndLoanCommitments": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CashReceiptsFromTheSaleOfLoansAndLoanCommitments",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlowsParenthetical"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cash Receipts From The Sale Of Loans And Loan Commitments",
        "terseLabel": "Cash receipts from the sale of loans and loan commitments within Non-core and Legacy",
        "documentation": "Net cash receipts from the sale of loan commitments within a business division."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_CategoriesOfFinancialAssetsAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "CategoriesOfFinancialAssetsAxis",
     "presentation": [
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Categories Of Financial Assets [Axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r166"
     ]
    },
    "ifrs-full_CategoriesOfFinancialLiabilitiesAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "CategoriesOfFinancialLiabilitiesAxis",
     "presentation": [
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Categories Of Financial Liabilities [Axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r166"
     ]
    },
    "ifrs-full_ChangeInValueOfForeignCurrencyBasisSpreadsAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ChangeInValueOfForeignCurrencyBasisSpreadsAbstract",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Change In Value Of Foreign Currency Basis Spreads [Abstract]",
        "terseLabel": "Cost of hedging"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_ChangesInAccountingPoliciesComparabilityAndAdjustmentsLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ChangesInAccountingPoliciesComparabilityAndAdjustmentsLineItems",
     "presentation": [
      "http://www.ubsag.com/role/ChangesInAccountingPoliciesComparabilityAndAdjustments"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Changes In Accounting Policies Comparability And Adjustments [Line Items]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_ChangesInExpectedCreditLossesScenariosMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ChangesInExpectedCreditLossesScenariosMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpenseReleaseNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Changes In Expected Credit Losses Scenarios [Member]",
        "documentation": "This member stands for changes in expected credit losses scenarios.",
        "terseLabel": "Scenario related"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_CivilDamageAwardDeductedFromBailOrderedFrenchCourtOfAppeal": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CivilDamageAwardDeductedFromBailOrderedFrenchCourtOfAppeal",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Civil Damage Award Deducted From Bail Ordered French Court Of Appeal",
        "terseLabel": "Civil damages award deducted from the bail, announcement of the French Court of Appeal",
        "documentation": "Civil damages award deducted from the bail following the verdict of the French Court of Appeal."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_CivilDamageAwardFrenchCourtOfAppeal": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CivilDamageAwardFrenchCourtOfAppeal",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Civil Damage Award French Court Of Appeal",
        "terseLabel": "Civil damages award, verdict of the French Court of Appeal",
        "documentation": "Civil damages award announced in the verdict of the French Court of Appeal."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_CivilDamageAwardOverturnedFrenchSupremeCourt": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CivilDamageAwardOverturnedFrenchSupremeCourt",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Civil Damage Award Overturned French Supreme Court",
        "terseLabel": "Civil damages award overturned French Supreme Court",
        "documentation": "Civil damages award decision overturned in the verdict of the French Supreme Court."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_CivilDamageAwardReimbursed": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CivilDamageAwardReimbursed",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Civil Damage Award Reimbursed",
        "terseLabel": "Civil damages award reimbursed",
        "documentation": "Civil damages award reimbursed."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_CivilDamageAwardSupremeCourtOfBermuda": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CivilDamageAwardSupremeCourtOfBermuda",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Civil Damage Award Supreme Court Of Bermuda",
        "terseLabel": "Civil damage award Supreme Court of Bermuda",
        "documentation": "Civil damages award announcement of the Supreme Court of Bermuda."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_CivilDamagesAwardFrenchCourt": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CivilDamagesAwardFrenchCourt",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Civil Damages Award French Court",
        "terseLabel": "Civil damages award announcement of the French Court",
        "documentation": "Civil damages award announcement of the French Court."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_ClaimsResolved": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ClaimsResolved",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Claims Resolved",
        "terseLabel": "Claimed damages that have been resolved",
        "documentation": "The amount of claims resolved through settlements, arbitration or withdrawal of the claim."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ClassesOfEmployeeBenefitsExpenseAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ClassesOfEmployeeBenefitsExpenseAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Classes Of Employee Benefits Expense [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ClassesOfFinancialInstrumentsAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ClassesOfFinancialInstrumentsAxis",
     "presentation": [
      "http://www.ubsag.com/role/DerivativeInstrumentsTables",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementECLrelevantBalanceSheetAndOffbalanceSheetPositionsIncludingECLAllowancesAndProvisionsNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Classes Of Financial Instruments [Axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r151",
      "r153",
      "r158",
      "r159"
     ]
    },
    "ifrs-full_ClassesOfFinancialInstrumentsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ClassesOfFinancialInstrumentsMember",
     "presentation": [
      "http://www.ubsag.com/role/DerivativeInstrumentsTables",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementECLrelevantBalanceSheetAndOffbalanceSheetPositionsIncludingECLAllowancesAndProvisionsNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Classes Of Financial Instruments [Member]",
        "terseLabel": "Total",
        "verboseLabel": "Total"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for aggregated classes of financial instruments. Financial instruments are contracts that give rise to a financial asset of one entity and a financial liability or equity instrument of another entity. It also represents the standard value for the 'Classes of financial instruments' axis if no other member is used. [Refer: Financial assets; Financial liabilities]"
       }
      }
     },
     "auth_ref": [
      "r151",
      "r153",
      "r158",
      "r159"
     ]
    },
    "ifrs-full_ClassesOfProvisionsAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ClassesOfProvisionsAxis",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersDetail",
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail",
      "http://www.ubsag.com/role/ProvisionsAdditionalInformationDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Classes Of Provisions [Axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r59"
     ]
    },
    "ubsag_ClientAssetsSeizedDecisionSwissFederalCriminalCourt": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ClientAssetsSeizedDecisionSwissFederalCriminalCourt",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Client Assets Seized Decision Swiss Federal Criminal Court",
        "terseLabel": "Client assets seized decision Swiss Federal Criminal Court",
        "documentation": "The amount of client assets seized by the court."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ClosingForeignExchangeRate": {
     "xbrltype": "decimalItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ClosingForeignExchangeRate",
     "presentation": [
      "http://www.ubsag.com/role/BasisOfAccountingCurrencyTranslationRatesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Closing Foreign Exchange Rate",
        "terseLabel": "Spot rate",
        "verboseLabel": "Closing exchange rate"
       }
      },
      "en": {
       "role": {
        "documentation": "The spot exchange rate at the end of the reporting period. Exchange rate is the ratio of exchange for two currencies. Spot exchange rate is the exchange rate for immediate delivery."
       }
      }
     },
     "auth_ref": [
      "r247"
     ]
    },
    "ubsag_CommercialpaperandcertificatesofdepositmemberMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CommercialpaperandcertificatesofdepositmemberMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Commercial Paper And Certificates Of Deposit Member [Member]",
        "terseLabel": "Commercial paper and certificates of deposit",
        "documentation": "This member relates to commercial paper and certificates of deposit."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_CommittedRevocableCreditLinesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CommittedRevocableCreditLinesMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Committed Revocable Credit Lines [Member]",
        "terseLabel": "Committed unconditionally revocable credit lines",
        "documentation": "This member relates to committed revocable credit lines.",
        "verboseLabel": "Unconditionally revocable loan commitments"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_CommodityContractsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CommodityContractsMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail",
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Commodity Contracts [Member]",
        "terseLabel": "Commodity contracts",
        "documentation": "This member relates to commodity contracts."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_CommodityLinkedIssuedDebtInstrumentsDesignatedAtFairValueThroughProfitOrLoss": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CommodityLinkedIssuedDebtInstrumentsDesignatedAtFairValueThroughProfitOrLoss",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueDetail": {
       "parentTag": "ubsag_DebtSecuritiesIssuedAtFairValueThroughProfitOrLossDesignatedAsUponInitialRecognition",
       "weight": 1.0,
       "order": 7.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Commodity Linked Issued Debt Instruments Designated At Fair Value Through Profit Or Loss",
        "documentation": "The amount of commodity-linked debt instruments that have been issued and are designated at fair value.",
        "terseLabel": "Commodity-linked"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_CommodityPriceRiskMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "CommodityPriceRiskMember",
     "presentation": [
      "http://www.ubsag.com/role/DerivativeInstrumentsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Commodity Price Risk [Member]",
        "terseLabel": "Commodity",
        "verboseLabel": "Commodity"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a component of other price risk that represents the type of risk that the fair value or future cash flows of a financial instrument will fluctuate because of changes in commodity prices. [Refer: Financial instruments, class [member]]"
       }
      }
     },
     "auth_ref": [
      "r229",
      "r239"
     ]
    },
    "ubsag_CommodityTradeFinanceMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CommodityTradeFinanceMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Commodity Trade Finance [Member]",
        "terseLabel": "Commodity trade finance",
        "documentation": "This member relates to commodity trade finance.",
        "verboseLabel": "of which: Commodity trade finance"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_CompensationrelatedLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CompensationrelatedLiabilities",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/OtherNonfinancialLiabilitiesDetail": {
       "parentTag": "ifrs-full_OtherNonfinancialLiabilities",
       "weight": 1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherNonfinancialLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "totalLabel": "Compensation-related liabilities",
        "documentation": "The amount of compensation-related liabilities.",
        "label": "Compensation-related Liabilities"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_CompensatoryClaimOrderedDecisionSwissFederalCriminalCourt": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CompensatoryClaimOrderedDecisionSwissFederalCriminalCourt",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Compensatory Claim Ordered Decision Swiss Federal Criminal Court",
        "terseLabel": "Compensatory claim ordered decision Swiss Federal Criminal Court",
        "documentation": "The amount of compensatory claim to be paid."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ComponentsOfEquityAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ComponentsOfEquityAxis",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity",
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquityParenthetical",
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Components Of Equity [Axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r6"
     ]
    },
    "ifrs-full_ComprehensiveIncome": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ComprehensiveIncome",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      },
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity",
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "terseLabel": "Total comprehensive income for the period",
        "label": "Comprehensive Income",
        "totalLabel": "Total comprehensive income",
        "verboseLabel": "Total comprehensive income"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of change in equity resulting from transactions and other events, other than those changes resulting from transactions with owners in their capacity as owners."
       }
      }
     },
     "auth_ref": [
      "r1",
      "r25",
      "r85",
      "r87",
      "r91",
      "r208"
     ]
    },
    "ifrs-full_ComprehensiveIncomeAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ComprehensiveIncomeAbstract",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Comprehensive Income [Abstract]",
        "terseLabel": "Total comprehensive income"
       }
      }
     },
     "auth_ref": []
    },
    "srt_CondensedCashFlowStatementTable": {
     "xbrltype": "stringItemType",
     "nsuri": "http://fasb.org/srt/2023",
     "localname": "CondensedCashFlowStatementTable",
     "presentation": [
      "http://www.ubsag.com/role/SupplementalGuarantorConsolidatedStatementOfCashFlowsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Condensed Cash Flow Statement [Table]"
       }
      }
     },
     "auth_ref": []
    },
    "srt_CondensedCashFlowStatementsCaptionsLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://fasb.org/srt/2023",
     "localname": "CondensedCashFlowStatementsCaptionsLineItems",
     "presentation": [
      "http://www.ubsag.com/role/SupplementalGuarantorConsolidatedStatementOfCashFlowsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Condensed Cash Flow Statements Captions [Line Items]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_CondensedFinancialInformationOfParentCompanyOnlyDisclosureTextBlock": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CondensedFinancialInformationOfParentCompanyOnlyDisclosureTextBlock",
     "presentation": [
      "http://www.ubsag.com/role/SupplementalGuarantorInformationRequiredUnderSECRegulations"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Condensed Financial Information Of Parent Company Only Disclosure [Text Block]",
        "documentation": "The entire disclosure for condensed financial information, including the financial position, cash flows, and the results of operations of the registrant (parent company) as of the same dates or for the same periods for which audited consolidated financial statements are being presented. Alternatively, the details of this disclosure can be reported by the specific parent company taxonomy elements, indicating the appropriate date and period contexts in an instance document."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_ConfiscationOverturnedFrenchSupremeCourt": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ConfiscationOverturnedFrenchSupremeCourt",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Confiscation Overturned French Supreme Court",
        "terseLabel": "Confiscation overturned French Supreme Court",
        "documentation": "Confiscation decision overturned in the verdict of the French Supreme Court."
       }
      }
     },
     "auth_ref": []
    },
    "srt_ConsolidatedEntitiesAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "http://fasb.org/srt/2023",
     "localname": "ConsolidatedEntitiesAxis",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail",
      "http://www.ubsag.com/role/SupplementalGuarantorConsolidatedStatementOfCashFlowsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Consolidated Entities [Axis]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_ConsolidatedEntitiesDomainMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ConsolidatedEntitiesDomainMember",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail",
      "http://www.ubsag.com/role/SupplementalGuarantorConsolidatedStatementOfCashFlowsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Consolidated Entities Domain [Member]",
        "terseLabel": "UBS AG (consolidated)",
        "documentation": "Entity or group of entities consolidated into reporting entity."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_ConsolidatedItemsDomainMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ConsolidatedItemsDomainMember",
     "presentation": [
      "http://www.ubsag.com/role/SupplementalGuarantorConsolidatedStatementOfCashFlowsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Consolidated Items Domain [Member]",
        "documentation": "Components, elimination, non-segment corporate-level activity and reconciling items used in consolidating a parent entity and its subsidiaries or its operating segments.",
        "terseLabel": "Consolidated items domain"
       }
      }
     },
     "auth_ref": []
    },
    "srt_ConsolidationEliminationsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://fasb.org/srt/2023",
     "localname": "ConsolidationEliminationsMember",
     "presentation": [
      "http://www.ubsag.com/role/SupplementalGuarantorConsolidatedStatementOfCashFlowsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Consolidation Eliminations [Member]",
        "terseLabel": "Elimination entries"
       }
      }
     },
     "auth_ref": []
    },
    "srt_ConsolidationItemsAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "http://fasb.org/srt/2023",
     "localname": "ConsolidationItemsAxis",
     "presentation": [
      "http://www.ubsag.com/role/SupplementalGuarantorConsolidatedStatementOfCashFlowsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Consolidation Items [Axis]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_ConsumerFinancingMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ConsumerFinancingMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Consumer Financing [Member]",
        "terseLabel": "Consumer financing",
        "documentation": "This member relates to consumer financing.",
        "verboseLabel": "of which: Consumer financing"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_ContractorEmployeeExpense": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ContractorEmployeeExpense",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/PersonnelExpensesDetail": {
       "parentTag": "ifrs-full_EmployeeBenefitsExpense",
       "weight": 1.0,
       "order": 4.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/PersonnelExpensesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Contractor Employee Expense",
        "terseLabel": "Contractors",
        "documentation": "The amout of expense for services rendered by contractors (individuals which are employed by a third party or self-employed)"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_CorporateAndMunicipalBondsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CorporateAndMunicipalBondsMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail",
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail",
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Corporate And Municipal Bonds [Member]",
        "terseLabel": "Corporate and municipal bonds",
        "documentation": "This member relates to corporate and municipal bonds.",
        "verboseLabel": "Financial assets and liabilities at fair value held for trading, Financial assets at fair value not held for trading: Corporate and municipal bonds"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_CorporateLendingMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CorporateLendingMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementECLrelevantBalanceSheetAndOffbalanceSheetPositionsIncludingECLAllowancesAndProvisionsNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Corporate Lending [Member]",
        "terseLabel": "Total corporate lending",
        "documentation": "This member relates to loans made to corporate entities and small and medium-sized enterprise."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_CorporateLoansMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "CorporateLoansMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Corporate Loans [Member]",
        "terseLabel": "Large corporate clients",
        "verboseLabel": "of which: Large corporate clients"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for loans made to corporate entities."
       }
      }
     },
     "auth_ref": [
      "r230",
      "r236",
      "r247"
     ]
    },
    "ifrs-full_CounterpartiesAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "CounterpartiesAxis",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementECLrelevantBalanceSheetAndOffbalanceSheetPositionsIncludingECLAllowancesAndProvisionsNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Counterparties [Axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r169"
     ]
    },
    "ifrs-full_CounterpartiesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "CounterpartiesMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementECLrelevantBalanceSheetAndOffbalanceSheetPositionsIncludingECLAllowancesAndProvisionsNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Counterparties [Member]",
        "terseLabel": "Total"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for the parties to the transaction other than the entity. It also represents the standard value for the 'Counterparties' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r169"
     ]
    },
    "ubsag_CreditCardMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CreditCardMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Credit Card [Member]",
        "terseLabel": "Credit cards",
        "documentation": "This member relates to credit cards.",
        "verboseLabel": "of which: Credit cards"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_CreditCorrelationMeasurementInputMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CreditCorrelationMeasurementInputMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Credit Correlation Measurement Input [Member]",
        "terseLabel": "Credit correlation",
        "documentation": "This member stands for credit correlation used as a measurement input."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_CreditDerivativeContractsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CreditDerivativeContractsMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail",
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "This member relates to credit derivative contracts.",
        "terseLabel": "Credit derivative contracts",
        "label": "Credit Derivative Contracts [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_CreditDerivativeContractsNetMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CreditDerivativeContractsNetMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsSensitivityToChangesInUnobservableInputAssumptionsDetail",
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Credit Derivative Contracts Net [Member]",
        "terseLabel": "Credit derivative contracts, net",
        "documentation": "This member relates to credit derivative contracts, net.",
        "verboseLabel": "Derivative financial instruments: Credit derivative contracts"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_CreditImpairmentOfFinancialInstrumentsAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "CreditImpairmentOfFinancialInstrumentsAxis",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementChangesToECLModelsScenariosScenarioWeightsAndPostmodelAdjustmentsNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpenseReleaseNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpensereleaseDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementECLrelevantBalanceSheetAndOffbalanceSheetPositionsIncludingECLAllowancesAndProvisionsNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Credit Impairment Of Financial Instruments [Axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r151",
      "r158"
     ]
    },
    "ifrs-full_CreditImpairmentOfFinancialInstrumentsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "CreditImpairmentOfFinancialInstrumentsMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementChangesToECLModelsScenariosScenarioWeightsAndPostmodelAdjustmentsNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpenseReleaseNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpensereleaseDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementECLrelevantBalanceSheetAndOffbalanceSheetPositionsIncludingECLAllowancesAndProvisionsNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Credit Impairment Of Financial Instruments [Member]",
        "terseLabel": "Total credit-impaired financial assets",
        "verboseLabel": "Total"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for all statuses of credit impairment of financial instruments. A financial instrument is credit-impaired when one or more events that have a detrimental impact on the estimated future cash flows of that financial instrument have occurred. This member also represents the standard value for the 'Credit impairment of financial instruments' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r151",
      "r158"
     ]
    },
    "ubsag_CreditLinkedIssuedDebtInstrumentsDesignatedAtFairValueThroughProfitOrLoss": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CreditLinkedIssuedDebtInstrumentsDesignatedAtFairValueThroughProfitOrLoss",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueDetail": {
       "parentTag": "ubsag_DebtSecuritiesIssuedAtFairValueThroughProfitOrLossDesignatedAsUponInitialRecognition",
       "weight": 1.0,
       "order": 5.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Credit Linked Issued Debt Instruments Designated At Fair Value Through Profit Or Loss",
        "terseLabel": "Credit-linked",
        "documentation": "The amount of credit-linked debt instruments that have been issued and are designated at fair value."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_CreditRiskMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "CreditRiskMember",
     "presentation": [
      "http://www.ubsag.com/role/DerivativeInstrumentsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "terseLabel": "Credit derivative",
        "label": "Credit Risk [Member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for the risk that one party to a financial instrument will cause a financial loss for the other party by failing to discharge an obligation. [Refer: Financial instruments, class [member]]"
       }
      }
     },
     "auth_ref": [
      "r121",
      "r122",
      "r123",
      "r227"
     ]
    },
    "ifrs-full_CreditSpreadMeasurementInputMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "CreditSpreadMeasurementInputMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "terseLabel": "Credit spread",
        "label": "Credit Spread Measurement Input [Member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for the credit spread used as a measurement input."
       }
      }
     },
     "auth_ref": [
      "r262"
     ]
    },
    "ubsag_CreditSuisseAGMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CreditSuisseAGMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Credit Suisse AG [Member]",
        "terseLabel": "Amounts due from banks against Credit Suisse AG",
        "documentation": "This member stands for amounts due from banks against Credit Suisse AG."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_CreditSuisseMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CreditSuisseMember",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Credit Suisse [Member]",
        "terseLabel": "Credit Suisse",
        "documentation": "This member stands for Credit Suisse."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_CreditValuationAdjustments": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CreditValuationAdjustments",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/FVMValuationAdjustmentsReservesOnTheBalanceSheetDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Credit Valuation Adjustments",
        "terseLabel": "Credit valuation adjustments",
        "documentation": "The amount of valuation adjustments made on financial instruments which represents the estimated fair value of protection required to hedge the counterparty credit risk of OTC derivative instruments, including funded derivative instruments that are classified as Financial assets at fair value not held for trading."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_CreditVolatilityMeasurementInputMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CreditVolatilityMeasurementInputMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Credit Volatility Measurement Input [Member]",
        "terseLabel": "Credit volatility",
        "documentation": "This member stands for credit volatility used as a measurement input."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_CrossBorderWealthManagementBusinessesInvestigationInBelgiumMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CrossBorderWealthManagementBusinessesInvestigationInBelgiumMember",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cross Border Wealth Management Businesses Investigation In Belgium [Member]",
        "terseLabel": "Inquiries regarding cross-border wealth management businesses | Investigation in Belgium",
        "documentation": "This member refers to inquiries regarding cross-border wealth management businesses in Belgium."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_CrossBorderWealthManagementBusinessesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CrossBorderWealthManagementBusinessesMember",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Cross Border Wealth Management Businesses [Member]",
        "terseLabel": "Inquiries regarding cross-border wealth management businesses | Investigations in France",
        "documentation": "This member refers to inquiries regarding cross-border wealth management businesses."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_CurrencyRiskMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "CurrencyRiskMember",
     "presentation": [
      "http://www.ubsag.com/role/DerivativeInstrumentsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Currency Risk [Member]",
        "terseLabel": "Foreign exchange",
        "verboseLabel": "Foreign exchange"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a type of market risk representing the risk that the fair value or future cash flows of a financial instrument will fluctuate because of changes in foreign exchange rates. [Refer: Financial instruments, class [member]]"
       }
      }
     },
     "auth_ref": [
      "r121",
      "r122",
      "r123",
      "r124",
      "r171"
     ]
    },
    "ubsag_CurrencyTranslationRateAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CurrencyTranslationRateAxis",
     "presentation": [
      "http://www.ubsag.com/role/BasisOfAccountingCurrencyTranslationRatesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Currency Translation Rate [Axis]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_CurrentAccruedExpensesAndOtherCurrentLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "CurrentAccruedExpensesAndOtherCurrentLiabilities",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/OtherFinancialLiabilitiesMeasuredAtAmortizedCostDetail": {
       "parentTag": "ubsag_OtherFinancialLiabilitiesAtAmortisedCost",
       "weight": 1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherFinancialLiabilitiesMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Current Accrued Expenses And Other Current Liabilities",
        "terseLabel": "Other accrued expenses"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of current accrued expenses and other current liabilities. [Refer: Accruals; Other current liabilities]"
       }
      }
     },
     "auth_ref": [
      "r249"
     ]
    },
    "ifrs-full_CurrentDebtInstrumentsIssued": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "CurrentDebtInstrumentsIssued",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostDetail": {
       "parentTag": "ifrs-full_DebtSecurities",
       "weight": 1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Current Debt Instruments Issued",
        "totalLabel": "Short-term debt",
        "terseLabel": "Short-term debt"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of current debt instruments issued. [Refer: Debt instruments issued]"
       }
      }
     },
     "auth_ref": [
      "r249"
     ]
    },
    "dei_CurrentFiscalYearEndDate": {
     "xbrltype": "gMonthDayItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2023",
     "localname": "CurrentFiscalYearEndDate",
     "presentation": [
      "http://www.ubsag.com/role/DocumentAndEntityInformation"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Current Fiscal Year End Date",
        "terseLabel": "Current fiscal year end date",
        "documentation": "End date of current fiscal year in the format --MM-DD."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_CurrentTaxAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "CurrentTaxAssets",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/OtherNonfinancialAssetsDetail": {
       "parentTag": "ifrs-full_OtherNonfinancialAssets",
       "weight": 1.0,
       "order": 5.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherNonfinancialAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "CurrentTaxAssets",
        "terseLabel": "Current tax assets"
       }
      },
      "en": {
       "role": {
        "documentation": "The excess of amount paid for current tax in respect of current and prior periods over the amount due for those periods. Current tax is the amount of income taxes payable (recoverable) in respect of the taxable profit (tax loss) for a period."
       }
      }
     },
     "auth_ref": [
      "r12"
     ]
    },
    "ifrs-full_CurrentTaxLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "CurrentTaxLiabilities",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/OtherNonfinancialLiabilitiesDetail": {
       "parentTag": "ifrs-full_OtherNonfinancialLiabilities",
       "weight": 1.0,
       "order": 8.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherNonfinancialLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Current Tax Liabilities",
        "terseLabel": "Current tax liabilities"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of current tax for current and prior periods to the extent unpaid. Current tax is the amount of income taxes payable (recoverable) in respect of the taxable profit (tax loss) for a period."
       }
      }
     },
     "auth_ref": [
      "r12"
     ]
    },
    "ubsag_CustomerAccountMattersMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "CustomerAccountMattersMember",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Customer Account Matters [Member]",
        "terseLabel": "Customer account matters",
        "documentation": "This members refers to customer account matters."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DOJRMBSSettlementMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DOJRMBSSettlementMember",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "DOJ RMBS Settlement [Member]",
        "terseLabel": "Mortgage-related matters | DOJ RMBS settlement",
        "documentation": "This member refers to settlement with the US Department of Justice related to Residential Mortgage-Backed Securities business."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DamageAwardGenevaCriminalCourt": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DamageAwardGenevaCriminalCourt",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Damage Award Geneva Criminal Court",
        "terseLabel": "Damage award Geneva criminal court",
        "documentation": "Damages award announced in the verdict of the Geneva criminal court."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DamageAwardSingaporeInternationalCommercialCourt": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DamageAwardSingaporeInternationalCommercialCourt",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Damage Award Singapore International Commercial Court",
        "terseLabel": "Damage award Singapore International Commercial Court",
        "documentation": "Damages award announced in the verdict of the Singapore International Commercial Court."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DateOfReclassificationOfFinancialAssetsDueToChangeInBusinessModel": {
     "xbrltype": "dateItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DateOfReclassificationOfFinancialAssetsDueToChangeInBusinessModel",
     "presentation": [
      "http://www.ubsag.com/role/ReclassificationOfFinancialAssetsNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Date Of Reclassification Of Financial Assets Due To Change In Business Model",
        "terseLabel": "Date of reclassification of financial assets due to change in business model"
       }
      },
      "en": {
       "role": {
        "documentation": "The date of the reclassification of financial assets due to a change in the entity's business model for managing financial assets. [Refer: Financial assets]"
       }
      }
     },
     "auth_ref": [
      "r131"
     ]
    },
    "ubsag_DebtInstrumentsHeldMeasuredAtAmortizedCost": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DebtInstrumentsHeldMeasuredAtAmortizedCost",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/OtherFinancialAssetsMeasuredAtAmortizedCostDetail": {
       "parentTag": "ubsag_OtherFinancialAssetsAtAmortisedCost",
       "weight": 1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherFinancialAssetsMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Debt Instruments Held Measured At Amortized Cost",
        "terseLabel": "Debt securities",
        "documentation": "The amount of instruments representing indebtedness measured at amortized cost held by the entity."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DebtInstrumentsIssuedByCreditSuisseInternationalDesignatedAtFairValueThroughProfitOrLossWithMaturityGreaterThanOneYear": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DebtInstrumentsIssuedByCreditSuisseInternationalDesignatedAtFairValueThroughProfitOrLossWithMaturityGreaterThanOneYear",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Debt Instruments Issued By Credit Suisse International Designated At Fair Value Through Profit Or Loss With Maturity Greater Than One Year",
        "terseLabel": "of which: issued by Credit Suisse International with original maturity greater than one year",
        "documentation": "The amount of all types of debt instruments that have been issued by Credit Suisse International and are designated at fair value, with original maturity greater than one year."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DebtInstrumentsIssuedByUBSAGDesignatedAtFairValueThroughProfitOrLossWithMaturityGreaterThanOneYear": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DebtInstrumentsIssuedByUBSAGDesignatedAtFairValueThroughProfitOrLossWithMaturityGreaterThanOneYear",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Debt Instruments Issued By UBS AG Designated At Fair Value Through Profit Or Loss With Maturity Greater Than One Year",
        "terseLabel": "of which: issued by UBS AG with original maturity greater than one year",
        "documentation": "The amount of all types of debt instruments that have been issued by UBS AG and are designated at fair value, with original maturity greater than one year."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DebtInstrumentsIssuedByUBSAGDesignatedAtFairValueThroughProfitOrLossWithMaturityGreaterThanOneYearUnsecuredPortion": {
     "xbrltype": "percentItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DebtInstrumentsIssuedByUBSAGDesignatedAtFairValueThroughProfitOrLossWithMaturityGreaterThanOneYearUnsecuredPortion",
     "presentation": [
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Debt Instruments Issued By UBS AG Designated At Fair Value Through Profit Or Loss With Maturity Greater Than One Year Unsecured Portion",
        "terseLabel": "Unsecured portion of debt instruments issued by UBS AG with original maturity greater than one year",
        "documentation": "The percentage of unsecured debt instruments that have been issued by UBS AG and are designated at fair value, with original maturity greater than one year."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DebtSecurities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DebtSecurities",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_FinancialLiabilitiesAtAmortisedCost",
       "weight": 1.0,
       "order": 29.0
      },
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostDetail": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostDetail",
      "http://www.ubsag.com/role/FVMFinancialInstrumentsNotMeasuredAtFairValueLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Debt Securities",
        "terseLabel": "Debt issued measured at amortized cost",
        "totalLabel": "Total debt issued measured at amortized cost"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of instruments issued by the entity that represent indebtedness."
       }
      }
     },
     "auth_ref": [
      "r249"
     ]
    },
    "ubsag_DebtSecuritiesIssuedAtFairValueThroughProfitOrLossDesignatedAsUponInitialRecognition": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DebtSecuritiesIssuedAtFairValueThroughProfitOrLossDesignatedAsUponInitialRecognition",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail": {
       "parentTag": "ifrs-full_FinancialLiabilitiesAtFairValueThroughProfitOrLoss",
       "weight": 1.0,
       "order": 5.0
      },
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_FinancialLiabilitiesAtFairValueThroughProfitOrLoss",
       "weight": 1.0,
       "order": 35.0
      },
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueDetail": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueDetail",
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Debt Securities Issued At Fair Value Through Profit Or Loss Designated As Upon Initial Recognition",
        "terseLabel": "Debt issued designated at fair value",
        "documentation": "The amount of debt issued designated at fair value.",
        "totalLabel": "Total debt issued designated at fair value"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DebtSecuritiesIssuedAtFairValueThroughProfitOrLossDesignatedAsUponInitialRecognitionMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DebtSecuritiesIssuedAtFairValueThroughProfitOrLossDesignatedAsUponInitialRecognitionMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Debt Securities Issued At Fair Value Through Profit Or Loss Designated As UponInitial Recognition [Member]",
        "terseLabel": "Debt issued designated at fair value",
        "documentation": "This member stands for debt issued designated at fair value."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DebtSecuritiesIssuedAtFairValueThroughProfitOrLossDesignatedAsUponInitialRecognitionTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DebtSecuritiesIssuedAtFairValueThroughProfitOrLossDesignatedAsUponInitialRecognitionTransferredAsOfTheMergerDate",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Debt Securities Issued At Fair Value Through Profit Or Loss Designated As Upon Initial Recognition Transferred As Of The Merger Date",
        "terseLabel": "Debt issued designated at fair value",
        "documentation": "The amount of debt issued designated at fair value."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DebtSecuritiesTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DebtSecuritiesTransferredAsOfTheMergerDate",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Debt Securities Transferred As Of The Merger Date",
        "terseLabel": "Debt issued measured at amortized cost",
        "documentation": "The amount of instruments issued by the entity that represent indebtedness."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DebtSecuritiesUnsecuredPortion": {
     "xbrltype": "percentItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DebtSecuritiesUnsecuredPortion",
     "presentation": [
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Debt Securities Unsecured Portion",
        "terseLabel": "Unsecured portion of total debt issued measured at amortized cost",
        "documentation": "The percentage for unsecured portion of total debt issued measured at amortized cost balance, after excluding Covered bonds, Debt issued through the Swiss central mortgage institutions, and Other long-term debt."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DecreaseInFairValueMeasurementDueToChangeInMultipleUnobservableInputsToReflectReasonablyPossibleAlternativeAssumptionsAssetsAndLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DecreaseInFairValueMeasurementDueToChangeInMultipleUnobservableInputsToReflectReasonablyPossibleAlternativeAssumptionsAssetsAndLiabilities",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsSensitivityToChangesInUnobservableInputAssumptionsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Decrease In Fair Value Measurement Due To Change In Multiple Unobservable Inputs To Reflect Reasonably Possible Alternative Assumptions Assets And Liabilities",
        "terseLabel": "Decrease in fair value measurement due to change in multiple unobservable inputs to reflect reasonably possible alternative assumptions, assets",
        "documentation": "The amount of decrease in the fair value measurement of assets due to a change in multiple unobservable inputs to reflect reasonably possible alternative assumptions.",
        "negatedLabel": "Unfavorable changes"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DeferredContingentCapitalPlanLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DeferredContingentCapitalPlanLiabilities",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/OtherNonfinancialLiabilitiesDetail": {
       "parentTag": "ubsag_CompensationrelatedLiabilities",
       "weight": 1.0,
       "order": 3.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherNonfinancialLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Deferred Contingent Capital Plan Liabilities",
        "terseLabel": "of which: Deferred Contingent Capital Plan",
        "documentation": "The amount of compensation-related liabilities related to Deferred Contingent Capital Plan (DCCP)."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DeferredDay1ProfitOrLossLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DeferredDay1ProfitOrLossLineItems",
     "presentation": [
      "http://www.ubsag.com/role/FVMValuationAdjustmentsDeferredDay1PLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Deferred Day-1 Profit Or Loss [Line Items]",
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with domain members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DeferredIncomeOther": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DeferredIncomeOther",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/OtherNonfinancialLiabilitiesDetail": {
       "parentTag": "ifrs-full_OtherNonfinancialLiabilities",
       "weight": 1.0,
       "order": 11.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherNonfinancialLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Deferred Income Other",
        "terseLabel": "Deferred income",
        "documentation": "The amount of liability representing income that has been received but is not yet earned."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DeferredTaxAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DeferredTaxAssets",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_Assets",
       "weight": 1.0,
       "order": 20.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Deferred Tax Assets",
        "terseLabel": "Deferred tax assets",
        "totalLabel": "Recognized"
       }
      },
      "en": {
       "role": {
        "documentation": "The amounts of income taxes recoverable in future periods in respect of: (a) deductible temporary differences; (b) the carryforward of unused tax losses; and (c) the carryforward of unused tax credits. [Refer: Temporary differences [member]; Unused tax credits [member]; Unused tax losses [member]]"
       }
      }
     },
     "auth_ref": [
      "r13",
      "r17",
      "r41"
     ]
    },
    "ubsag_DeferredTaxAssetsTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DeferredTaxAssetsTransferredAsOfTheMergerDate",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Deferred Tax Assets Transferred As Of The Merger Date",
        "terseLabel": "Deferred tax assets",
        "documentation": "The amounts of income taxes recoverable in future periods in respect of: (a) deductible temporary differences; (b) the carryforward of unused tax losses; and (c) the carryforward of unused tax credits. [Refer: Temporary differences [member]; Unused tax credits [member]; Unused tax losses [member]]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DeferredTaxLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DeferredTaxLiabilities",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/OtherNonfinancialLiabilitiesDetail": {
       "parentTag": "ifrs-full_OtherNonfinancialLiabilities",
       "weight": 1.0,
       "order": 9.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherNonfinancialLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Deferred Tax Liabilities",
        "totalLabel": "Total deferred tax liabilities",
        "terseLabel": "Deferred tax liabilities"
       }
      },
      "en": {
       "role": {
        "documentation": "The amounts of income taxes payable in future periods in respect of taxable temporary differences. [Refer: Temporary differences [member]]"
       }
      }
     },
     "auth_ref": [
      "r13",
      "r17",
      "r41"
     ]
    },
    "ifrs-full_DepositsFromBanks": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DepositsFromBanks",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_FinancialLiabilitiesAtAmortisedCost",
       "weight": 1.0,
       "order": 24.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/FVMFinancialInstrumentsNotMeasuredAtFairValueLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Deposits From Banks",
        "terseLabel": "Amounts due to banks",
        "verboseLabel": "Amounts due to banks"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of deposit liabilities from banks held by the entity."
       }
      }
     },
     "auth_ref": [
      "r249"
     ]
    },
    "ubsag_DepositsFromBanksTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DepositsFromBanksTransferredAsOfTheMergerDate",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Deposits From Banks Transferred As Of The Merger Date",
        "terseLabel": "Amounts due to banks",
        "documentation": "The amount of deposit liabilities from banks held by the entity."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DepositsFromCustomers": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DepositsFromCustomers",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_FinancialLiabilitiesAtAmortisedCost",
       "weight": 1.0,
       "order": 27.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/FVMFinancialInstrumentsNotMeasuredAtFairValueLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Deposits From Customers",
        "terseLabel": "Customer deposits",
        "totalLabel": "Due to customers",
        "verboseLabel": "Customer deposits (formerly: Due to customers)"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of deposit liabilities from customers held by the entity."
       }
      }
     },
     "auth_ref": [
      "r249"
     ]
    },
    "ubsag_DepositsFromCustomersTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DepositsFromCustomersTransferredAsOfTheMergerDate",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Deposits From Customers Transferred As Of The Merger Date",
        "terseLabel": "Customer deposits",
        "documentation": "The amount of deposit liabilities from customers held by the entity."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DepreciationAmortisationAndImpairmentLossReversalOfImpairmentLossRecognisedInProfitOrLoss": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DepreciationAmortisationAndImpairmentLossReversalOfImpairmentLossRecognisedInProfitOrLoss",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement": {
       "parentTag": "ifrs-full_ExpenseByNature",
       "weight": 1.0,
       "order": 15.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Depreciation Amortisation And Impairment Loss Reversal Of Impairment Loss Recognised In Profit Or Loss",
        "terseLabel": "Depreciation, amortization and impairment of non-financial assets"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of depreciation expense, amortisation expense and impairment loss (reversal of impairment loss) recognised in profit or loss. [Refer: Depreciation and amortisation expense; Impairment loss (reversal of impairment loss) recognised in profit or loss]"
       }
      }
     },
     "auth_ref": [
      "r247"
     ]
    },
    "ubsag_DerivativeAssetsAndLiabilitiesNotionalAmount": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DerivativeAssetsAndLiabilitiesNotionalAmount",
     "presentation": [
      "http://www.ubsag.com/role/DerivativeInstrumentsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Derivative Assets And Liabilities Notional Amount",
        "terseLabel": "Notional amounts related to derivative financial assets and liabilities",
        "documentation": "The nominal or face amount of derivative assets and liabilities, used to calculate payments made on these instruments."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DerivativeFinancialAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DerivativeFinancialAssets",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail": {
       "parentTag": "ubsag_AssetsMeasuredAtFairValue",
       "weight": 1.0,
       "order": 3.0
      },
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_FinancialAssetsAtFairValueThroughProfitOrLoss",
       "weight": 1.0,
       "order": 12.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/DerivativeInstrumentsDetail",
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Derivative Financial Assets",
        "verboseLabel": "Derivative financial instruments",
        "terseLabel": "Derivative financial assets",
        "positiveTerseLabel": "Derivative financial instruments (formerly: Positive replacement values)",
        "positiveVerboseLabel": "Derivative financial assets"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of financial assets classified as derivative instruments. [Refer: Financial assets; Derivatives [member]]"
       }
      }
     },
     "auth_ref": [
      "r249"
     ]
    },
    "ubsag_DerivativeFinancialAssetsOfAcquireeTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DerivativeFinancialAssetsOfAcquireeTransferredAsOfTheMergerDate",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Derivative Financial Assets Of Acquiree Transferred As Of The Merger Date",
        "terseLabel": "Derivative financial assets",
        "documentation": "The amount of financial assets classified as derivative instruments. [Refer: Financial assets; Derivatives [member]]",
        "verboseLabel": "Derivative financial instruments"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DerivativeFinancialLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DerivativeFinancialLiabilities",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail": {
       "parentTag": "ifrs-full_FinancialLiabilitiesAtFairValueThroughProfitOrLoss",
       "weight": 1.0,
       "order": 3.0
      },
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_FinancialLiabilitiesAtFairValueThroughProfitOrLoss",
       "weight": 1.0,
       "order": 33.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/DerivativeInstrumentsDetail",
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Derivative Financial Liabilities",
        "terseLabel": "NRV",
        "verboseLabel": "Derivative financial liabilities",
        "positiveTerseLabel": "Derivative financial instruments (formerly: Negative replacement values)",
        "positiveVerboseLabel": "Derivative financial instruments"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of financial liabilities classified as derivative instruments. [Refer: Financial assets; Derivatives [member]]"
       }
      }
     },
     "auth_ref": [
      "r249"
     ]
    },
    "ubsag_DerivativeFinancialLiabilitiesTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DerivativeFinancialLiabilitiesTransferredAsOfTheMergerDate",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Derivative Financial Liabilities Transferred As Of The Merger Date",
        "terseLabel": "Derivative financial instruments",
        "documentation": "The amount of financial liabilities classified as derivative instruments. [Refer: Financial assets; Derivatives [member]]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DerivativeLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DerivativeLineItems",
     "presentation": [
      "http://www.ubsag.com/role/DerivativeInstruments",
      "http://www.ubsag.com/role/DerivativeInstrumentsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Derivative [Line Items]",
        "terseLabel": "Derivative instruments",
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with domain members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DerivativeTable": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DerivativeTable",
     "presentation": [
      "http://www.ubsag.com/role/DerivativeInstrumentsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Derivative [Table]",
        "documentation": "Schedule that describes and identifies a derivative or group of derivatives on a disaggregated basis, such as for individual instruments, or small groups of similar instruments. May include a combination of the type of instrument, risks being hedged, notional amount, hedge designation, related hedged item, inception date, maturity date, or other relevant item."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DerivativesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DerivativesMember",
     "presentation": [
      "http://www.ubsag.com/role/DerivativeInstrumentsTables",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail",
      "http://www.ubsag.com/role/OffsettingFinancialAssetsDetail",
      "http://www.ubsag.com/role/OffsettingFinancialLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Derivatives [Member]",
        "terseLabel": "Total derivative instruments, based on IFRS netting",
        "verboseLabel": "Derivative financial instruments"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for financial instruments or other contracts within the scope of IFRS 9 with all three of the following characteristics: (a) Their value changes in response to the change in a specified interest rate, financial instrument price, commodity price, foreign exchange rate, index of prices or rates, credit rating or credit index, or other variable, provided in the case of a non-financial variable that the variable is not specific to a party to the contract (sometimes called the \u2018underlying\u2019); (b) They require no initial net investment or an initial net investment that is smaller than would be required for other types of contracts that would be expected to have a similar response to changes in market factors; (c) They are settled at a future date. [Refer: Financial instruments, class [member]]"
       }
      }
     },
     "auth_ref": [
      "r211",
      "r217",
      "r230",
      "r240"
     ]
    },
    "ubsag_DescriptionOfAccountingPolicyForBusinessCombinationsUnderCommonControlExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DescriptionOfAccountingPolicyForBusinessCombinationsUnderCommonControlExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/BasisOfAccountingPolicy"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Description Of Accounting Policy For Business Combinations Under Common Control Explanatory",
        "terseLabel": "Business combinations under common control",
        "documentation": "Description of accounting policy for business combinations under common control."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DescriptionOfAccountingPolicyForImpairmentOfFinancialAssetsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DescriptionOfAccountingPolicyForImpairmentOfFinancialAssetsExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/BasisOfAccountingPolicy"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Description Of Accounting Policy For Impairment Of Financial Assets Explanatory",
        "terseLabel": "Allowances and provisions for expected credit losses"
       }
      },
      "en": {
       "role": {
        "documentation": "The description of the entity's material accounting policy information for the impairment of financial assets. [Refer: Financial assets]"
       }
      }
     },
     "auth_ref": [
      "r248"
     ]
    },
    "ifrs-full_DescriptionOfAccountingPolicyForIntangibleAssetsAndGoodwillExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DescriptionOfAccountingPolicyForIntangibleAssetsAndGoodwillExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/BasisOfAccountingPolicy"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Description Of Accounting Policy For Intangible Assets And Goodwill Explanatory",
        "terseLabel": "Goodwill and other intangible assets"
       }
      },
      "en": {
       "role": {
        "documentation": "The description of the entity's material accounting policy information for intangible assets and goodwill. [Refer: Intangible assets and goodwill]"
       }
      }
     },
     "auth_ref": [
      "r248"
     ]
    },
    "ifrs-full_DescriptionOfExpectedImpactOfInitialApplicationOfNewStandardsOrInterpretations": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DescriptionOfExpectedImpactOfInitialApplicationOfNewStandardsOrInterpretations",
     "presentation": [
      "http://www.ubsag.com/role/ChangesInAccountingPoliciesComparabilityAndAdjustments"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Description Of Expected Impact Of Initial Application Of New Standards Or Interpretations",
        "terseLabel": "Expected impact of initial application of new standards or interpretations"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of the known or reasonably estimable information relevant to assessing the possible impact that the application of a new IFRS, that has been issued but is not yet effective, will have."
       }
      }
     },
     "auth_ref": [
      "r82"
     ]
    },
    "ifrs-full_DesignatedFinancialLiabilitiesAtFairValueThroughProfitOrLossAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DesignatedFinancialLiabilitiesAtFairValueThroughProfitOrLossAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Designated Financial Liabilities At Fair Value Through Profit Or Loss [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DilutedEarningsLossPerShare": {
     "xbrltype": "perShareItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DilutedEarningsLossPerShare",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Diluted Earnings Loss Per Share",
        "terseLabel": "Diluted"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of profit (loss) attributable to ordinary equity holders of the parent entity (the numerator), divided by the weighted average number of ordinary shares outstanding during the period (the denominator), both adjusted for the effects of all dilutive potential ordinary shares. [Refer: Ordinary shares [member]; Weighted average [member]]"
       }
      }
     },
     "auth_ref": [
      "r52",
      "r53"
     ]
    },
    "ubsag_DisclosureAssetsLiabilitiesAndEquityTransferredOnTheMergerDateAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureAssetsLiabilitiesAndEquityTransferredOnTheMergerDateAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Assets Liabilities And Equity Transferred On The Merger Date [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureAssetsLiabilitiesAndEquityTransferredOnTheMergerDateLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureAssetsLiabilitiesAndEquityTransferredOnTheMergerDateLineItems",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Assets Liabilities And Equity Transferred On The Merger Date [Line Items]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureAssetsLiabilitiesAndEquityTransferredOnTheMergerDateTable": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureAssetsLiabilitiesAndEquityTransferredOnTheMergerDateTable",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Assets Liabilities And Equity Transferred On The Merger Date [Table]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureBasisOfAccountingAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureBasisOfAccountingAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Basis Of Accounting [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureBasisOfAccountingLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureBasisOfAccountingLineItems",
     "presentation": [
      "http://www.ubsag.com/role/BasisOfAccountingNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Basis Of Accounting [Line Items]",
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with domain members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureNetInterestIncomeExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureNetInterestIncomeExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/NetInterestIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Net Interest Income Explanatory",
        "documentation": "The disclosure of net interest income.",
        "terseLabel": "Net interest income"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureNetInterestIncomeLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureNetInterestIncomeLineItems",
     "presentation": [
      "http://www.ubsag.com/role/NetInterestIncome",
      "http://www.ubsag.com/role/NetInterestIncomeTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Net Interest Income [Line Items]",
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with domain members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureNetInterestIncomeTablesExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureNetInterestIncomeTablesExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/NetInterestIncomeTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Net Interest Income Tables Explanatory",
        "documentation": "The disclosure of net interest income.",
        "terseLabel": "Net interest income"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfAssetsLiabilitiesAndEquityTransferredTablesExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfAssetsLiabilitiesAndEquityTransferredTablesExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Assets Liabilities And Equity Transferred Tables Explanatory",
        "documentation": "The disclosure of assets, liabilities and equity transferred in table format.",
        "terseLabel": "Credit Suisse AG assets, liabilities and equity transferred to UBS AG on the merger date"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfBasisOfPreparationOfFinancialStatementsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfBasisOfPreparationOfFinancialStatementsExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/BasisOfAccountingPolicy"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Basis Of Preparation Of Financial Statements Explanatory",
        "terseLabel": "Basis of preparation"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of the basis used for the preparation of the financial statements."
       }
      }
     },
     "auth_ref": [
      "r245"
     ]
    },
    "ubsag_DisclosureOfBusinessCombinationsUnderCommonControlAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfBusinessCombinationsUnderCommonControlAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Business Combinations Under Common Control [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfBusinessCombinationsUnderCommonControlExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfBusinessCombinationsUnderCommonControlExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAG"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Business Combinations Under Common Control Explanatory",
        "terseLabel": "Accounting for the merger of UBS AG and Credit Suisse AG",
        "documentation": "The entire disclosure for business combinations under common control."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfBusinessCombinationsUnderCommonControlLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfBusinessCombinationsUnderCommonControlLineItems",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAG",
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Business Combinations Under Common Control [Line items]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfChangesInAccountingPoliciesAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfChangesInAccountingPoliciesAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Changes In Accounting Policies [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfChangesInAccountingPoliciesAccountingEstimatesAndErrorsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfChangesInAccountingPoliciesAccountingEstimatesAndErrorsExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/ChangesInAccountingPoliciesComparabilityAndAdjustments"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Changes In Accounting Policies Accounting Estimates And Errors Explanatory",
        "terseLabel": "Changes in accounting policies, comparability and adjustments"
       }
      },
      "en": {
       "role": {
        "documentation": "The entire disclosure for changes in accounting policies, accounting estimates and errors."
       }
      }
     },
     "auth_ref": [
      "r83"
     ]
    },
    "ifrs-full_DisclosureOfContingentLiabilitiesExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfContingentLiabilitiesExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMatters"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Contingent Liabilities Explanatory"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of contingent liabilities. [Refer: Contingent liabilities [member]]"
       }
      }
     },
     "auth_ref": [
      "r60"
     ]
    },
    "ubsag_DisclosureOfCoverageRatiosExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfCoverageRatiosExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Coverage Ratios Explanatory",
        "terseLabel": "Coverage ratios"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfCreditLossExpenseRecoveryExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfCreditLossExpenseRecoveryExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Credit Loss Expense Recovery Explanatory",
        "terseLabel": "Credit loss expense recovery"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfCreditRiskExposureExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfCreditRiskExposureExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Credit Risk Exposure Explanatory",
        "terseLabel": "Credit risk exposure"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of the credit risk exposure. Credit risk exposure is the credit risk inherent in an entity\u2019s financial assets and commitments to extend credit."
       }
      }
     },
     "auth_ref": [
      "r158"
     ]
    },
    "ifrs-full_DisclosureOfCreditRiskExposureLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfCreditRiskExposureLineItems",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Credit Risk Exposure [Line Items]"
       }
      },
      "en": {
       "role": {
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfCreditRiskExposureTable": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfCreditRiskExposureTable",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Credit Risk Exposure [Table]"
       }
      },
      "en": {
       "role": {
        "documentation": "Schedule disclosing information related to the credit risk exposure."
       }
      }
     },
     "auth_ref": [
      "r158"
     ]
    },
    "ifrs-full_DisclosureOfDebtSecuritiesExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfDebtSecuritiesExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/DebtIssuedHeldAtAmortizedCost"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Debt Securities Explanatory",
        "terseLabel": "Disclosure of debt issued [text block]"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of debt instruments. [Refer: Debt instruments issued; Debt instruments held]"
       }
      }
     },
     "auth_ref": [
      "r245"
     ]
    },
    "ubsag_DisclosureOfDeferredDayOneProfitOrLossExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfDeferredDayOneProfitOrLossExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/FairValueMeasurementTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Deferred Day-One Profit Or Loss Explanatory",
        "documentation": "The disclosure of deferred day-one profit or loss."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfDerivativeFinancialAssetsAndLiabilitiesExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfDerivativeFinancialAssetsAndLiabilitiesExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/DerivativeInstrumentsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Derivative Financial Assets And Liabilities Explanatory",
        "documentation": "The disclosure of derivative financial assets and derivative financial liabilities."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfDerivativeFinancialAssetsAndLiabilitiesLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfDerivativeFinancialAssetsAndLiabilitiesLineItems",
     "presentation": [
      "http://www.ubsag.com/role/DerivativeInstrumentsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Derivative Financial Assets And Liabilities [Line Items]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfDerivativeFinancialInstrumentsAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfDerivativeFinancialInstrumentsAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Derivative Financial Instruments [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfDerivativeFinancialInstrumentsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfDerivativeFinancialInstrumentsExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/DerivativeInstruments"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Derivative Financial Instruments Explanatory"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of derivative financial instruments. [Refer: Derivatives [member]]"
       }
      }
     },
     "auth_ref": [
      "r245"
     ]
    },
    "ubsag_DisclosureOfDesignatedFinancialLiabilitiesAtFairValueThroughProfitOrLoss": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfDesignatedFinancialLiabilitiesAtFairValueThroughProfitOrLoss",
     "presentation": [
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueTable"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Designated Financial Liabilities At Fair Value Through Profit Or Loss",
        "terseLabel": "Disclosure of financial liabilities designated at fair value through profit or loss [text block]",
        "documentation": "The disclosure of financial liabilities designated at fair value through profit or loss."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfDetailedInformationAboutBorrowingsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfDetailedInformationAboutBorrowingsExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Detailed Information About Borrowings Explanatory"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of detailed information about borrowings. [Refer: Borrowings]"
       }
      }
     },
     "auth_ref": [
      "r264"
     ]
    },
    "ifrs-full_DisclosureOfDisaggregationOfRevenueFromContractsWithCustomersTable": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfDisaggregationOfRevenueFromContractsWithCustomersTable",
     "presentation": [
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Disaggregation Of Revenue From Contracts With Customers [Table]"
       }
      },
      "en": {
       "role": {
        "documentation": "Schedule disclosing information related to the disaggregation of revenue from contracts with customers."
       }
      }
     },
     "auth_ref": [
      "r110"
     ]
    },
    "ifrs-full_DisclosureOfEffectOfChangesInForeignExchangeRatesExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfEffectOfChangesInForeignExchangeRatesExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/CurrencyTranslationRates"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Effect Of Changes In Foreign Exchange Rates Explanatory",
        "terseLabel": "Currency translation rates"
       }
      },
      "en": {
       "role": {
        "documentation": "The entire disclosure for the effect of changes in foreign exchange rates."
       }
      }
     },
     "auth_ref": [
      "r48"
     ]
    },
    "ifrs-full_DisclosureOfEmployeeBenefitsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfEmployeeBenefitsExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/PersonnelExpenses"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Employee Benefits Explanatory",
        "terseLabel": "Personnel expenses"
       }
      },
      "en": {
       "role": {
        "documentation": "The entire disclosure for employee benefits."
       }
      }
     },
     "auth_ref": [
      "r45"
     ]
    },
    "ubsag_DisclosureOfEmployeeBenefitsTablesExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfEmployeeBenefitsTablesExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/PersonnelExpensesTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Employee Benefits Tables Explanatory",
        "terseLabel": "Personnel expenses"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfEntitysReportableSegmentsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfEntitysReportableSegmentsExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/SegmentReporting"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Entitys Reportable Segments Explanatory",
        "terseLabel": "Segment reporting"
       }
      },
      "en": {
       "role": {
        "documentation": "The entire disclosure for operating segments."
       }
      }
     },
     "auth_ref": [
      "r188"
     ]
    },
    "ifrs-full_DisclosureOfFairValueMeasurementExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfFairValueMeasurementExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/FairValueMeasurement"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Fair Value Measurement Explanatory"
       }
      },
      "en": {
       "role": {
        "documentation": "The entire disclosure for fair value measurement."
       }
      }
     },
     "auth_ref": [
      "r107"
     ]
    },
    "ubsag_DisclosureOfFairValueMeasurementLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfFairValueMeasurementLineItems",
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueMeasurementNarrativeDetail",
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail",
      "http://www.ubsag.com/role/FairValueMeasurement"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Fair Value Measurement [Line Items]",
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with domain members defined in one or many axes of the table.",
        "terseLabel": "Disclosure of significant unobservable inputs used in fair value measurement [line items]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfFairValueMeasurementOfAssetsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfFairValueMeasurementOfAssetsExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/FairValueMeasurementTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Fair Value Measurement Of Assets Explanatory"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of the fair value measurement of assets."
       }
      }
     },
     "auth_ref": [
      "r105"
     ]
    },
    "ifrs-full_DisclosureOfFairValueMeasurementOfAssetsLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfFairValueMeasurementOfAssetsLineItems",
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail",
      "http://www.ubsag.com/role/FVMFinancialInstrumentsNotMeasuredAtFairValueAssetsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Fair Value Measurement Of Assets [Line Items]",
        "terseLabel": "Movements of Level 3 instruments",
        "verboseLabel": "Financial instruments not measured at fair value"
       }
      },
      "en": {
       "role": {
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfFairValueMeasurementOfAssetsTable": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfFairValueMeasurementOfAssetsTable",
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail",
      "http://www.ubsag.com/role/FVMFinancialInstrumentsNotMeasuredAtFairValueAssetsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Fair Value Measurement Of Assets [Table]"
       }
      },
      "en": {
       "role": {
        "documentation": "Schedule disclosing information related to the fair value measurement of assets."
       }
      }
     },
     "auth_ref": [
      "r105"
     ]
    },
    "ifrs-full_DisclosureOfFairValueMeasurementOfLiabilitiesExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfFairValueMeasurementOfLiabilitiesExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/FairValueMeasurementTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Fair Value Measurement Of Liabilities Explanatory"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of the fair value measurement of liabilities."
       }
      }
     },
     "auth_ref": [
      "r105"
     ]
    },
    "ifrs-full_DisclosureOfFairValueMeasurementOfLiabilitiesLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfFairValueMeasurementOfLiabilitiesLineItems",
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail",
      "http://www.ubsag.com/role/FVMFinancialInstrumentsNotMeasuredAtFairValueLiabilitiesDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Fair Value Measurement Of Liabilities [Line Items]",
        "terseLabel": "Financial instruments not measured at fair value"
       }
      },
      "en": {
       "role": {
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfFairValueMeasurementOfLiabilitiesTable": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfFairValueMeasurementOfLiabilitiesTable",
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail",
      "http://www.ubsag.com/role/FVMFinancialInstrumentsNotMeasuredAtFairValueLiabilitiesDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Fair Value Measurement Of Liabilities [Table]"
       }
      },
      "en": {
       "role": {
        "documentation": "Schedule disclosing information related to the fair value measurement of liabilities."
       }
      }
     },
     "auth_ref": [
      "r105"
     ]
    },
    "ifrs-full_DisclosureOfFairValueOfFinancialInstrumentsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfFairValueOfFinancialInstrumentsExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/FairValueMeasurementTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Fair Value Of Financial Instruments Explanatory"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of the fair value of financial instruments. [Refer: Financial instruments, class [member]; At fair value [member]]"
       }
      }
     },
     "auth_ref": [
      "r245"
     ]
    },
    "ubsag_DisclosureOfFairValueOfFinancialInstrumentsNotMeasuredAtFairValueExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfFairValueOfFinancialInstrumentsNotMeasuredAtFairValueExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/FairValueMeasurementTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Fair Value Of Financial Instruments Not Measured At Fair Value Explanatory",
        "documentation": "The disclosure of the fair value of financial instruments not measured at fair value."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfFeeAndCommissionIncomeExpenseExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfFeeAndCommissionIncomeExpenseExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/NetFeeAndCommissionIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Fee And Commission Income Expense Explanatory",
        "terseLabel": "Net fee and commission income"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of fee and commission income (expense). [Refer: Fee and commission income (expense)]"
       }
      }
     },
     "auth_ref": [
      "r245"
     ]
    },
    "ubsag_DisclosureOfFeeAndCommissionIncomeExpenseTablesExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfFeeAndCommissionIncomeExpenseTablesExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Fee And Commission Income Expense Tables Explanatory",
        "terseLabel": "Net fee and commission income"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfFinancialAssetsLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfFinancialAssetsLineItems",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementTables",
      "http://www.ubsag.com/role/OtherFinancialAssetsMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Financial Assets [Line Item]",
        "terseLabel": "Allowances and provisions for credit losses"
       }
      },
      "en": {
       "role": {
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfFinancialInstrumentsAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfFinancialInstrumentsAbstract",
     "presentation": [
      "http://www.ubsag.com/role/FVMFinancialInstrumentsNotMeasuredAtFairValueAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Financial Instruments [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfFinancialInstrumentsDesignatedAtFairValueThroughProfitOrLossExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfFinancialInstrumentsDesignatedAtFairValueThroughProfitOrLossExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValue"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Financial Instruments Designated At Fair Value Through Profit Or Loss Explanatory"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of financial instruments designated at fair value through profit or loss. [Refer: At fair value [member]; Financial instruments, class [member]]"
       }
      }
     },
     "auth_ref": [
      "r245"
     ]
    },
    "ifrs-full_DisclosureOfFinancialLiabilitiesLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfFinancialLiabilitiesLineItems",
     "presentation": [
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValue",
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueDetail",
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueTable",
      "http://www.ubsag.com/role/DebtIssuedHeldAtAmortizedCost",
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostDetail",
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostTables",
      "http://www.ubsag.com/role/OtherFinancialLiabilitiesDesignatedAtFairValueDetail",
      "http://www.ubsag.com/role/OtherFinancialLiabilitiesMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Financial Liabilities [Line Items]",
        "terseLabel": "Debt issued held at amortized cost"
       }
      },
      "en": {
       "role": {
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfForeignExchangeRatesExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfForeignExchangeRatesExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/BasisOfAccountingTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Foreign Exchange Rates Explanatory",
        "terseLabel": "Currency translation rates",
        "documentation": "The disclosure of foreign exchange rates."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfFundingFromGroupAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfFundingFromGroupAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Funding From Group [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfFundingFromGroupExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfFundingFromGroupExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/FundingFromGroupMeasuredAtAmortizedCost"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Funding From Group Explanatory",
        "documentation": "The disclosure of funding from UBS Group AG measured at amortized cost.",
        "terseLabel": "Disclosure of funding from Group [textblock]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfFundingFromGroupLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfFundingFromGroupLineItems",
     "presentation": [
      "http://www.ubsag.com/role/FundingFromGroupMeasuredAtAmortizedCost",
      "http://www.ubsag.com/role/FundingFromGroupMeasuredAtAmortizedCostDetail",
      "http://www.ubsag.com/role/FundingFromGroupMeasuredAtAmortizedCostTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Funding From Group [Line Items]",
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with domain members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfFundingFromGroupTablesExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfFundingFromGroupTablesExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/FundingFromGroupMeasuredAtAmortizedCostTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Funding From Group Tables Explanatory",
        "documentation": "The disclosure of funding from UBS Group AG measured at amortized cost in table format.",
        "terseLabel": "Disclosure of funding from Group [textblock]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfGeneralAndAdministrativeExpenseAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfGeneralAndAdministrativeExpenseAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of General And Administrative Expense [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfGeneralAndAdministrativeExpenseExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfGeneralAndAdministrativeExpenseExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpenses"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of General And Administrative Expense Explanatory",
        "terseLabel": "General and administrative expenses"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of general and administrative expenses. [Refer: Administrative expenses]"
       }
      }
     },
     "auth_ref": [
      "r245"
     ]
    },
    "ubsag_DisclosureOfGeneralAndAdministrativeExpenseTablesExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfGeneralAndAdministrativeExpenseTablesExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of General And Administrative Expense Tables Explanatory",
        "terseLabel": "General and administrative expenses"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfKeyMacroEconomicVariablesExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfKeyMacroEconomicVariablesExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Key Macro Economic Variables Explanatory",
        "documentation": "The disclosure of the key macro-economic variables used for modelling ECL.",
        "terseLabel": "Key macro economic variables"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfKeyMacroEconomicVariablesUsedForExpectedCreditLossModelLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfKeyMacroEconomicVariablesUsedForExpectedCreditLossModelLineItems",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementComparisonOfShockFactorsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure of Key Macro Economic Variables Used For Expected Credit Loss Model [Line Items]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfKeyMacroEconomicVariablesUsedForExpectedCreditLossModelTable": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfKeyMacroEconomicVariablesUsedForExpectedCreditLossModelTable",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementComparisonOfShockFactorsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Key Macro Economic Variables Used For Expected Credit Loss Model [Table]",
        "documentation": "Schedule disclosing information related to the relationship between key macro economic variables used for ECL model and expected credit loss."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfLegalProceedingsProvisionExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfLegalProceedingsProvisionExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Legal Proceedings Provision Explanatory",
        "terseLabel": "Disclosure of provisions for litigation, regulatory and similar matters [text block]",
        "documentation": "The disclosure of provisions for litigation, regulatory and similar matters."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfLevel3OfFairValueOfFinancialInstrumentsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfLevel3OfFairValueOfFinancialInstrumentsExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/FairValueMeasurementTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Level 3 Of Fair Value Of Financial Instruments Explanatory",
        "documentation": "The disclosure of the level 3 of fair value of financial instruments."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfLitigationRegulatoryAndSimilarMattersAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfLitigationRegulatoryAndSimilarMattersAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Litigation Regulatory And Similar Matters [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfLitigationRegulatoryAndSimilarMattersLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfLitigationRegulatoryAndSimilarMattersLineItems",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMatters",
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Litigation Regulatory And Similar Matters [Line Items]",
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with domain members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfLitigationRegulatoryAndSimilarMattersSegmentsTable": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfLitigationRegulatoryAndSimilarMattersSegmentsTable",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Litigation Regulatory And Similar Matters Segments [Table]",
        "documentation": "Schedule disclosing information related to litigation, regulatory and similar matters per operating segment."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfLitigationRegulatoryAndSimilarMattersTable": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfLitigationRegulatoryAndSimilarMattersTable",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Litigation Regulatory And Similar Matters [Table]",
        "documentation": "Schedule disclosing information related to litigation, regulatory and similar matters."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfMaterialAccountingPoliciesAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfMaterialAccountingPoliciesAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Material Accounting Policies [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfMaterialAccountingPoliciesDescriptionsLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfMaterialAccountingPoliciesDescriptionsLineItems",
     "presentation": [
      "http://www.ubsag.com/role/BasisOfAccountingPolicy"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Material Accounting Policies Descriptions [Line Items]",
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with domain members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfMaterialAccountingPolicyInformationExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfMaterialAccountingPolicyInformationExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/BasisOfAccounting"
     ],
     "lang": {
      "en-us": {
       "role": {
        "terseLabel": "Basis of preparation",
        "label": "Disclosure Of Material Accounting Policy Information Explanatory"
       }
      },
      "en": {
       "role": {
        "documentation": "The entire disclosure of material accounting policy information applied by the entity."
       }
      }
     },
     "auth_ref": [
      "r7"
     ]
    },
    "ubsag_DisclosureOfMaterialAccountingPolicyInformationLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfMaterialAccountingPolicyInformationLineItems",
     "presentation": [
      "http://www.ubsag.com/role/BasisOfAccounting"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Material Accounting Policy Information [Line Items]",
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with domain members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfNetInterestIncomeAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfNetInterestIncomeAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Net Interest Income [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfOffsettingOfFinancialAssetsAndFinancialLiabilitiesExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfOffsettingOfFinancialAssetsAndFinancialLiabilitiesExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/DerivativeInstrumentsTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Offsetting Of Financial Assets And Liabilities Explanatory"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of the offsetting of financial assets and financial liabilities. [Refer: Financial assets; Financial liabilities]"
       }
      }
     },
     "auth_ref": [
      "r172"
     ]
    },
    "ifrs-full_DisclosureOfOffsettingOfFinancialAssetsLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfOffsettingOfFinancialAssetsLineItems",
     "presentation": [
      "http://www.ubsag.com/role/OffsettingFinancialAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Offsetting Of Financial Assets [Line Items]"
       }
      },
      "en": {
       "role": {
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfOffsettingOfFinancialAssetsTable": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfOffsettingOfFinancialAssetsTable",
     "presentation": [
      "http://www.ubsag.com/role/OffsettingFinancialAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Offsetting Of Financial Assets [Table]"
       }
      },
      "en": {
       "role": {
        "documentation": "Schedule disclosing information related to the offsetting of financial assets."
       }
      }
     },
     "auth_ref": [
      "r137"
     ]
    },
    "ifrs-full_DisclosureOfOffsettingOfFinancialLiabilitiesLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfOffsettingOfFinancialLiabilitiesLineItems",
     "presentation": [
      "http://www.ubsag.com/role/OffsettingFinancialLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Offsetting Of Financial Liabilities [Line Items]",
        "terseLabel": "Financial liabilities subject to offsetting, enforceable master netting arrangements and similar agreements"
       }
      },
      "en": {
       "role": {
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfOffsettingOfFinancialLiabilitiesTable": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfOffsettingOfFinancialLiabilitiesTable",
     "presentation": [
      "http://www.ubsag.com/role/OffsettingFinancialLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Offsetting Of Financial Liabilities [Table]"
       }
      },
      "en": {
       "role": {
        "documentation": "Schedule disclosing information related to the offsetting of financial liabilities."
       }
      }
     },
     "auth_ref": [
      "r137"
     ]
    },
    "ifrs-full_DisclosureOfOperatingSegmentsAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfOperatingSegmentsAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Operating Segments [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfOperatingSegmentsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfOperatingSegmentsExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/SegmentReportingTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Operating Segments Explanatory",
        "terseLabel": "Segment reporting"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of operating segments. [Refer: Operating segments [member]]"
       }
      }
     },
     "auth_ref": [
      "r176"
     ]
    },
    "ifrs-full_DisclosureOfOperatingSegmentsLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfOperatingSegmentsLineItems",
     "presentation": [
      "http://www.ubsag.com/role/SegmentReporting",
      "http://www.ubsag.com/role/SegmentReportingDetail",
      "http://www.ubsag.com/role/SegmentReportingNarrativeDetail",
      "http://www.ubsag.com/role/SegmentReportingTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Operating Segments [Line Items]",
        "verboseLabel": "Segment reporting"
       }
      },
      "en": {
       "role": {
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfOperatingSegmentsTable": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfOperatingSegmentsTable",
     "presentation": [
      "http://www.ubsag.com/role/SegmentReportingDetail",
      "http://www.ubsag.com/role/SegmentReportingNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Operating Segments [Table]"
       }
      },
      "en": {
       "role": {
        "documentation": "Schedule disclosing information related to operating segments."
       }
      }
     },
     "auth_ref": [
      "r176"
     ]
    },
    "ubsag_DisclosureOfOtherAssetsAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfOtherAssetsAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Other Assets [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfOtherAssetsAndOtherLiabilitiesAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfOtherAssetsAndOtherLiabilitiesAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Other Assets And Other Liabilities [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfOtherAssetsAndOtherLiabilitiesExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfOtherAssetsAndOtherLiabilitiesExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/OtherAssetsAndLiabilities"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Other Assets And Other Liabilities Explanatory",
        "terseLabel": "Disclosure of other assets and other liabilities [textblock]",
        "documentation": "The disclosure of other assets and other liabilities."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfOtherFinancialAssetsMeasuredAtAmortisedCostExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfOtherFinancialAssetsMeasuredAtAmortisedCostExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/OtherAssetsAndLiabilitiesTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Other Financial Assets Measured At Amortised Cost Explanatory",
        "documentation": "The disclosure of other financial assets measured at amortised cost."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfOtherFinancialLiabilitiesMeasuredAtAmortizedCostExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfOtherFinancialLiabilitiesMeasuredAtAmortizedCostExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/OtherAssetsAndLiabilitiesTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Other Financial Liabilities Measured At Amortized Cost Explanatory",
        "documentation": "The disclosure of other financial liabilities measured at amortized cost."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfOtherFinancialLiabilitiesMeasuredAtFairValueExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfOtherFinancialLiabilitiesMeasuredAtFairValueExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/OtherAssetsAndLiabilitiesTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Other Financial Liabilities Measured At Fair Value Explanatory",
        "documentation": "The disclosure of other financial liabilities measured at fair value."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfOtherIncomeAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfOtherIncomeAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Other Income [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfOtherLiabilitiesAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfOtherLiabilitiesAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Other Liabilities [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfOtherNonFinancialAssetsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfOtherNonFinancialAssetsExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/OtherAssetsAndLiabilitiesTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Other Non Financial Assets Explanatory",
        "documentation": "The disclosure of other non-financial assets."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfOtherNonFinancialLiabilitiesExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfOtherNonFinancialLiabilitiesExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/OtherAssetsAndLiabilitiesTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Other Non Financial Liabilities Explanatory",
        "documentation": "The disclosure of other non-financial liabilities."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfOtherOperatingIncomeExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfOtherOperatingIncomeExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/OtherIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Other Operating Income Explanatory"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of other operating income. [Refer: Other operating income (expense)]"
       }
      }
     },
     "auth_ref": [
      "r245"
     ]
    },
    "ubsag_DisclosureOfOtherOperatingIncomeTablesExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfOtherOperatingIncomeTablesExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/OtherIncomeTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Other Operating Income Tables Explanatory",
        "documentation": "The disclosure of other operating income in table format."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfOtherProvisionsAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfOtherProvisionsAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Other Provisions [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfOtherProvisionsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfOtherProvisionsExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/ProvisionsAndContingentLiabilitiesTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Other Provisions Explanatory",
        "terseLabel": "Total provisions with additional information [textblock]"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of other provisions. [Refer: Other provisions]"
       }
      }
     },
     "auth_ref": [
      "r59"
     ]
    },
    "ifrs-full_DisclosureOfOtherProvisionsLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfOtherProvisionsLineItems",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersDetail",
      "http://www.ubsag.com/role/Provisions",
      "http://www.ubsag.com/role/ProvisionsAdditionalInformationDetail",
      "http://www.ubsag.com/role/ProvisionsAndContingentLiabilitiesTables",
      "http://www.ubsag.com/role/ProvisionsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Other Provisions [Line Items]",
        "terseLabel": "Provisions",
        "verboseLabel": "Total Provisions"
       }
      },
      "en": {
       "role": {
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfOtherProvisionsTable": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfOtherProvisionsTable",
     "presentation": [
      "http://www.ubsag.com/role/ProvisionsAdditionalInformationDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Provisions [Table]"
       }
      },
      "en": {
       "role": {
        "documentation": "Schedule disclosing information related to other provisions."
       }
      }
     },
     "auth_ref": [
      "r59"
     ]
    },
    "ifrs-full_DisclosureOfProvisionMatrixAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfProvisionMatrixAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Provision Matrix [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfProvisionMatrixDetailsAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfProvisionMatrixDetailsAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Provision Matrix Details [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfProvisionMatrixExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfProvisionMatrixExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurement"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Provision Matrix Explanatory",
        "terseLabel": "Expected credit loss measurement"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of the provision matrix."
       }
      }
     },
     "auth_ref": [
      "r228"
     ]
    },
    "ifrs-full_DisclosureOfProvisionMatrixLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfProvisionMatrixLineItems",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurement",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementChangesToECLModelsScenariosScenarioWeightsAndPostmodelAdjustmentsNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpenseReleaseNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpensereleaseDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementECLrelevantBalanceSheetAndOffbalanceSheetPositionsIncludingECLAllowancesAndProvisionsNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementEconomicScenariosAndWeightsAppliedDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Provision Matrix [Line Items]"
       }
      },
      "en": {
       "role": {
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfProvisionMatrixTable": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfProvisionMatrixTable",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementChangesToECLModelsScenariosScenarioWeightsAndPostmodelAdjustmentsNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpenseReleaseNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpensereleaseDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementECLrelevantBalanceSheetAndOffbalanceSheetPositionsIncludingECLAllowancesAndProvisionsNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementEconomicScenariosAndWeightsAppliedDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Provision Matrix [Table]"
       }
      },
      "en": {
       "role": {
        "documentation": "Schedule disclosing information related to the provision matrix."
       }
      }
     },
     "auth_ref": [
      "r228"
     ]
    },
    "ubsag_DisclosureOfProvisionsBreakdownExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfProvisionsBreakdownExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/ProvisionsAndContingentLiabilitiesTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Provisions Breakdown Explanatory",
        "terseLabel": "Total provisions recognized under both IAS 37 and IFRS 9 [textblock]",
        "documentation": "The disclosure of provisions."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfProvisionsExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfProvisionsExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/Provisions"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Provisions Explanatory"
       }
      },
      "en": {
       "role": {
        "documentation": "The disclosure of provisions. [Refer: Provisions]"
       }
      }
     },
     "auth_ref": [
      "r245"
     ]
    },
    "ifrs-full_DisclosureOfReclassificationOfFinancialAssetsAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfReclassificationOfFinancialAssetsAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Reclassification Of Financial Assets [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfReclassificationOfFinancialAssetsLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfReclassificationOfFinancialAssetsLineItems",
     "presentation": [
      "http://www.ubsag.com/role/ReclassificationOfFinancialAssetsNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Reclassification Of Financial Assets [Line Items]"
       }
      },
      "en": {
       "role": {
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DisclosureOfReclassificationOfFinancialAssetsTable": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DisclosureOfReclassificationOfFinancialAssetsTable",
     "presentation": [
      "http://www.ubsag.com/role/ReclassificationOfFinancialAssetsNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Reclassification Of Financial Assets [Table]"
       }
      },
      "en": {
       "role": {
        "documentation": "Schedule disclosing information related to the reclassification of financial assets."
       }
      }
     },
     "auth_ref": [
      "r133"
     ]
    },
    "ubsag_DisclosureOfSensitivityAnalysisOfFairValueMeasurementToChangesInUnobservableInputsAssetsAndLiabilitiesExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfSensitivityAnalysisOfFairValueMeasurementToChangesInUnobservableInputsAssetsAndLiabilitiesExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/FairValueMeasurementTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Sensitivity Analysis Of Fair Value Measurement To Changes In Unobservable Inputs Assets And Liabilities Explanatory"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfSensitivityAnalysisOfFairValueMeasurementToChangesInUnobservableInputsAssetsAndLiabilitiesLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfSensitivityAnalysisOfFairValueMeasurementToChangesInUnobservableInputsAssetsAndLiabilitiesLineItems",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsSensitivityToChangesInUnobservableInputAssumptionsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Sensitivity Analysis Of Fair Value Measurement To Changes In Unobservable Inputs Assets And Liabilities [Line Items]",
        "terseLabel": "Disclosure of sensitivity analysis of fair value measurement to changes in unobservable inputs, assets [line items]",
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with domain members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfSignificantUnobservableInputsUsedInFairValueMeasurementOfAssetsAndLiabilitiesExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfSignificantUnobservableInputsUsedInFairValueMeasurementOfAssetsAndLiabilitiesExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/FairValueMeasurementTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Significant Unobservable Inputs Used In Fair Value Measurement Of Assets And Liabilities Explanatory"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfSignificantUnobservableInputsUsedInFairValueMeasurementTable": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfSignificantUnobservableInputsUsedInFairValueMeasurementTable",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "Schedule disclosing information related to significant unobservable inputs used in the fair value measurement of assets and liabilities.",
        "label": "Disclosure Of Significant Unobservable Inputs Used In Fair Value Measurement [Table]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfSupplementalGuarantorInformationAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfSupplementalGuarantorInformationAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Supplemental Guarantor Information [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOfValuationAdjustmentReservesOnTheBalanceSheetExplanatory": {
     "xbrltype": "textBlockItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOfValuationAdjustmentReservesOnTheBalanceSheetExplanatory",
     "presentation": [
      "http://www.ubsag.com/role/FairValueMeasurementTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Of Valuation Adjustment Reserves On The Balance Sheet Explanatory",
        "documentation": "The disclosure of valuation adjustment reserves on the balance sheet."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DisclosureOffsettingFinancialAssetsAndFinancialLiabilitiesAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisclosureOffsettingFinancialAssetsAndFinancialLiabilitiesAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Disclosure Offsetting Financial Assets And Financial Liabilities [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DiscountRateMeasurementInputMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DiscountRateMeasurementInputMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Discount Rate Measurement Input [Member]",
        "terseLabel": "Discount margin"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a discount rate used as a measurement input used in valuation techniques based on a present value calculation."
       }
      }
     },
     "auth_ref": [
      "r262"
     ]
    },
    "ifrs-full_DiscountedCashFlowMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DiscountedCashFlowMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Discounted Cash Flow [Member]",
        "terseLabel": "Discounted expected cash flows"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a specific valuation technique consistent with the income approach that involves analysing future cash flow amounts through the application of present value techniques and inputs (for example, weighted average cost of capital, long-term revenue growth rate, long-term pre-tax operating margin, discount for lack of marketability, control premium). [Refer: Income approach [member]; Weighted average [member]]"
       }
      }
     },
     "auth_ref": [
      "r212",
      "r218"
     ]
    },
    "ubsag_DisposalAndRedemptionOfDebtSecuritiesMeasuredAtAmortizedCost": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DisposalAndRedemptionOfDebtSecuritiesMeasuredAtAmortizedCost",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInInvestingActivities",
       "weight": 1.0,
       "order": 33.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Disposal And Redemption Of Debt Securities Measured At Amortized Cost",
        "documentation": "The cash inflow from sales or maturity of debt securities measured at amortized cost.",
        "terseLabel": "Disposal and redemption of debt securities measured at amortized cost"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_DividendsPaidToEquityHoldersOfParentClassifiedAsFinancingActivities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DividendsPaidToEquityHoldersOfParentClassifiedAsFinancingActivities",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInFinancingActivities",
       "weight": -1.0,
       "order": 38.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Dividends Paid To Equity Holders Of Parent Classified As Financing Activities",
        "negatedLabel": "Distributions paid on UBS shares",
        "negatedTerseLabel": "Distributions paid on UBS AG shares"
       }
      },
      "en": {
       "role": {
        "documentation": "The cash outflow for dividends paid to equity holders of the parent, classified as financing activities."
       }
      }
     },
     "auth_ref": [
      "r257"
     ]
    },
    "ifrs-full_DividendsReceivedClassifiedAsOperatingActivities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "DividendsReceivedClassifiedAsOperatingActivities",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Dividends Received Classified As Operating Activities",
        "terseLabel": "Dividends on equity investments, investment funds and associates received in cash"
       }
      },
      "en": {
       "role": {
        "documentation": "The cash inflow from dividends received, classified as operating activities. [Refer: Dividends received]"
       }
      }
     },
     "auth_ref": [
      "r77"
     ]
    },
    "ubsag_DividendsRecognisedAsDistributions": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DividendsRecognisedAsDistributions",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Dividends Recognised As Distributions",
        "negatedLabel": "Dividends",
        "documentation": "Dividends recognised as distributions to owners of parent, preferred noteholders and non-controlling interests."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DocumentAndEntityInformationAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DocumentAndEntityInformationAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Document And Entity Information [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "dei_DocumentFiscalPeriodFocus": {
     "xbrltype": "fiscalPeriodItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2023",
     "localname": "DocumentFiscalPeriodFocus",
     "presentation": [
      "http://www.ubsag.com/role/DocumentAndEntityInformation"
     ],
     "lang": {
      "en-us": {
       "role": {
        "terseLabel": "Document fiscal period focus",
        "label": "Document Fiscal Period Focus",
        "documentation": "Fiscal period values are FY, Q1, Q2, and Q3.  1st, 2nd and 3rd quarter 10-Q or 10-QT statements have value Q1, Q2, and Q3 respectively, with 10-K, 10-KT or other fiscal year statements having FY."
       }
      }
     },
     "auth_ref": []
    },
    "dei_DocumentFiscalYearFocus": {
     "xbrltype": "gYearItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2023",
     "localname": "DocumentFiscalYearFocus",
     "presentation": [
      "http://www.ubsag.com/role/DocumentAndEntityInformation"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Document Fiscal Year Focus",
        "terseLabel": "Document fiscal year focus",
        "documentation": "This is focus fiscal year of the document report in YYYY format. For a 2006 annual report, which may also provide financial information from prior periods, fiscal 2006 should be given as the fiscal year focus. Example: 2006."
       }
      }
     },
     "auth_ref": []
    },
    "dei_DocumentPeriodEndDate": {
     "xbrltype": "dateItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2023",
     "localname": "DocumentPeriodEndDate",
     "presentation": [
      "http://www.ubsag.com/role/DocumentAndEntityInformation"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Document Period End Date",
        "terseLabel": "Document period end date",
        "documentation": "For the EDGAR submission types of Form 8-K: the date of the report, the date of the earliest event reported; for the EDGAR submission types of Form N-1A: the filing date; for all other submission types: the end of the reporting or transition period.  The format of the date is YYYY-MM-DD."
       }
      }
     },
     "auth_ref": []
    },
    "dei_DocumentType": {
     "xbrltype": "submissionTypeItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2023",
     "localname": "DocumentType",
     "presentation": [
      "http://www.ubsag.com/role/DocumentAndEntityInformation"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Document Type",
        "terseLabel": "Document type",
        "documentation": "The type of document being provided (such as 10-K, 10-Q, 485BPOS, etc). The document type is limited to the same value as the supporting SEC submission type, or the word 'Other'."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_DueFromBanksClassifiedAsCashEquivalents": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "DueFromBanksClassifiedAsCashEquivalents",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Due From Banks Classified As Cash Equivalents",
        "terseLabel": "Due from banks classified as cash equivalents",
        "documentation": "A classification of cash equivalents representing due from banks.",
        "verboseLabel": "Loans and advances to banks classified as cash equivalents",
        "positiveTerseLabel": "of which: amounts due from banks"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_EURCurrencyExchangeRateMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "EURCurrencyExchangeRateMember",
     "presentation": [
      "http://www.ubsag.com/role/BasisOfAccountingCurrencyTranslationRatesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "EUR Currency Exchange Rate [Member]",
        "terseLabel": "1 EUR",
        "documentation": "This member stands for currency translation rate of 1 EUR to the presentation currency."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_EarningsPerShareAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "EarningsPerShareAbstract",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Earnings Per Share [Abstract]",
        "terseLabel": "Earnings per share"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_EconomicAssumptionsAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "EconomicAssumptionsAxis",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementComparisonOfShockFactorsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Economic Assumptions [Axis]",
        "documentation": "The axis of a table defines the relationship between the domain members or categories in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_EconomicAssumptionsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "EconomicAssumptionsMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementComparisonOfShockFactorsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Economic Assumptions [Member]",
        "documentation": "This member stands for all types of economic assumptions."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_EconomicForecast": {
     "xbrltype": "percentItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "EconomicForecast",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementComparisonOfShockFactorsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Economic Forecast",
        "terseLabel": "Economic forecast",
        "documentation": "The forecasted amount of economic assumptions. A positive amount indicates growth projections whereas a negative amount indicates deficit projection."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_EffectOfChangeInMethodologyOfAllocationOfBalanceSheetResourcesFromGroupFunctionsToBusinessDivisionsIfAppliedRetrospectively": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "EffectOfChangeInMethodologyOfAllocationOfBalanceSheetResourcesFromGroupFunctionsToBusinessDivisionsIfAppliedRetrospectively",
     "presentation": [
      "http://www.ubsag.com/role/SegmentReportingDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Effect Of Change In Methodology Of Allocation Of Balance Sheet Resources From Group Functions To Business Divisions If Applied Retrospectively",
        "documentation": "The potential effect on prior-period reported values of refined methodology applied to allocate balance sheet resources from Group Functions to the business divisions, with prospective effect, if applied retrospectively."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_EffectOfExchangeRateChangesOnCashAndCashEquivalents": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "EffectOfExchangeRateChangesOnCashAndCashEquivalents",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Effect Of Exchange Rate Changes On Cash And Cash Equivalents",
        "terseLabel": "Effects of exchange rate differences on cash and cash equivalents"
       }
      },
      "en": {
       "role": {
        "documentation": "The effect of exchange rate changes on cash and cash equivalents held or due in a foreign currency. [Refer: Cash and cash equivalents]"
       }
      }
     },
     "auth_ref": [
      "r75",
      "r76"
     ]
    },
    "ifrs-full_EmployeeBenefitsExpense": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "EmployeeBenefitsExpense",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement": {
       "parentTag": "ifrs-full_ExpenseByNature",
       "weight": 1.0,
       "order": 13.0
      },
      "http://www.ubsag.com/role/PersonnelExpensesDetail": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement",
      "http://www.ubsag.com/role/PersonnelExpensesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Employee Benefits Expense",
        "terseLabel": "Personnel expenses",
        "totalLabel": "Total personnel expenses"
       }
      },
      "en": {
       "role": {
        "documentation": "The expense of all forms of consideration given by an entity in exchange for a service rendered by employees or for the termination of employment."
       }
      }
     },
     "auth_ref": [
      "r0",
      "r36",
      "r195"
     ]
    },
    "dei_EntityCentralIndexKey": {
     "xbrltype": "centralIndexKeyItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2023",
     "localname": "EntityCentralIndexKey",
     "presentation": [
      "http://www.ubsag.com/role/DocumentAndEntityInformation"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entity Central Index Key",
        "terseLabel": "Entity central index key",
        "documentation": "A unique 10-digit SEC-issued value to identify entities that have filed disclosures with the SEC. It is commonly abbreviated as CIK."
       }
      }
     },
     "auth_ref": [
      "r244"
     ]
    },
    "dei_EntityDomain": {
     "xbrltype": "domainItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2023",
     "localname": "EntityDomain",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAG",
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail",
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGTables",
      "http://www.ubsag.com/role/BasisOfAccounting",
      "http://www.ubsag.com/role/BasisOfAccountingCurrencyTranslationRatesDetail",
      "http://www.ubsag.com/role/BasisOfAccountingNarrativeDetail",
      "http://www.ubsag.com/role/BasisOfAccountingPolicy",
      "http://www.ubsag.com/role/BasisOfAccountingTables",
      "http://www.ubsag.com/role/ChangesInAccountingPoliciesComparabilityAndAdjustments",
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement",
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows",
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlowsParenthetical",
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity",
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquityParenthetical",
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome",
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncomeParenthetical",
      "http://www.ubsag.com/role/CurrencyTranslationRates",
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValue",
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueDetail",
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueTable",
      "http://www.ubsag.com/role/DebtIssuedHeldAtAmortizedCost",
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostDetail",
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostTables",
      "http://www.ubsag.com/role/DerivativeInstruments",
      "http://www.ubsag.com/role/DerivativeInstrumentsDetail",
      "http://www.ubsag.com/role/DerivativeInstrumentsTables",
      "http://www.ubsag.com/role/DocumentAndEntityInformation",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurement",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementChangesToECLModelsScenariosScenarioWeightsAndPostmodelAdjustmentsNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementComparisonOfShockFactorsDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpenseReleaseNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpensereleaseDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementECLrelevantBalanceSheetAndOffbalanceSheetPositionsIncludingECLAllowancesAndProvisionsNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementEconomicScenariosAndWeightsAppliedDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementTables",
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail",
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail",
      "http://www.ubsag.com/role/FVMFairValueMeasurementNarrativeDetail",
      "http://www.ubsag.com/role/FVMFinancialInstrumentsNotMeasuredAtFairValueAssetsDetail",
      "http://www.ubsag.com/role/FVMFinancialInstrumentsNotMeasuredAtFairValueLiabilitiesDetail",
      "http://www.ubsag.com/role/FVMLevel3InstrumentsSensitivityToChangesInUnobservableInputAssumptionsDetail",
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail",
      "http://www.ubsag.com/role/FVMValuationAdjustmentsDeferredDay1PLDetail",
      "http://www.ubsag.com/role/FVMValuationAdjustmentsReservesOnTheBalanceSheetDetail",
      "http://www.ubsag.com/role/FairValueMeasurement",
      "http://www.ubsag.com/role/FairValueMeasurementTables",
      "http://www.ubsag.com/role/FundingFromGroupMeasuredAtAmortizedCost",
      "http://www.ubsag.com/role/FundingFromGroupMeasuredAtAmortizedCostDetail",
      "http://www.ubsag.com/role/FundingFromGroupMeasuredAtAmortizedCostTables",
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpenses",
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesDetail",
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesTables",
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMatters",
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersDetail",
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail",
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersTables",
      "http://www.ubsag.com/role/NetFeeAndCommissionIncome",
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail",
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeTables",
      "http://www.ubsag.com/role/NetInterestIncome",
      "http://www.ubsag.com/role/NetInterestIncomeDetail",
      "http://www.ubsag.com/role/NetInterestIncomeTables",
      "http://www.ubsag.com/role/OffsettingFinancialAssetsDetail",
      "http://www.ubsag.com/role/OffsettingFinancialLiabilitiesDetail",
      "http://www.ubsag.com/role/OtherAssetsAndLiabilities",
      "http://www.ubsag.com/role/OtherAssetsAndLiabilitiesTables",
      "http://www.ubsag.com/role/OtherFinancialAssetsMeasuredAtAmortizedCostDetail",
      "http://www.ubsag.com/role/OtherFinancialLiabilitiesDesignatedAtFairValueDetail",
      "http://www.ubsag.com/role/OtherFinancialLiabilitiesMeasuredAtAmortizedCostDetail",
      "http://www.ubsag.com/role/OtherIncome",
      "http://www.ubsag.com/role/OtherIncomeDetail",
      "http://www.ubsag.com/role/OtherIncomeTables",
      "http://www.ubsag.com/role/OtherNonfinancialAssetsDetail",
      "http://www.ubsag.com/role/OtherNonfinancialLiabilitiesDetail",
      "http://www.ubsag.com/role/PersonnelExpenses",
      "http://www.ubsag.com/role/PersonnelExpensesDetail",
      "http://www.ubsag.com/role/PersonnelExpensesTables",
      "http://www.ubsag.com/role/Provisions",
      "http://www.ubsag.com/role/ProvisionsAdditionalInformationDetail",
      "http://www.ubsag.com/role/ProvisionsAndContingentLiabilitiesTables",
      "http://www.ubsag.com/role/ProvisionsDetail",
      "http://www.ubsag.com/role/ReclassificationOfFinancialAssetsNarrativeDetail",
      "http://www.ubsag.com/role/SegmentReporting",
      "http://www.ubsag.com/role/SegmentReportingDetail",
      "http://www.ubsag.com/role/SegmentReportingNarrativeDetail",
      "http://www.ubsag.com/role/SegmentReportingTables",
      "http://www.ubsag.com/role/SupplementalGuarantorConsolidatedStatementOfCashFlowsDetail",
      "http://www.ubsag.com/role/SupplementalGuarantorInformationNarrativeDetail",
      "http://www.ubsag.com/role/SupplementalGuarantorInformationRequiredUnderSECRegulations"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entity [Domain]",
        "terseLabel": "UBS Group AG",
        "verboseLabel": "UBS Group AG (consolidated)",
        "documentation": "All the names of the entities being reported upon in a document. Any legal structure used to conduct activities or to hold assets. Some examples of such structures are corporations, partnerships, limited liability companies, grantor trusts, and other trusts. This item does not include business and geographical segments which are included in the geographical or business segments domains."
       }
      }
     },
     "auth_ref": []
    },
    "dei_EntityInformationLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2023",
     "localname": "EntityInformationLineItems",
     "presentation": [
      "http://www.ubsag.com/role/DocumentAndEntityInformation"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entity Information [Line Items]",
        "documentation": "Line items represent financial concepts included in a table. These concepts are used to disclose reportable information associated with domain members defined in one or many axes to the table."
       }
      }
     },
     "auth_ref": []
    },
    "dei_EntityRegistrantName": {
     "xbrltype": "normalizedStringItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2023",
     "localname": "EntityRegistrantName",
     "presentation": [
      "http://www.ubsag.com/role/DocumentAndEntityInformation"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entity Registrant Name",
        "terseLabel": "Entity registrant name",
        "documentation": "The exact name of the entity filing the report as specified in its charter, which is required by forms filed with the SEC."
       }
      }
     },
     "auth_ref": [
      "r244"
     ]
    },
    "ubsag_EntityTable": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "EntityTable",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAG",
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGTables",
      "http://www.ubsag.com/role/BasisOfAccounting",
      "http://www.ubsag.com/role/BasisOfAccountingNarrativeDetail",
      "http://www.ubsag.com/role/BasisOfAccountingPolicy",
      "http://www.ubsag.com/role/BasisOfAccountingTables",
      "http://www.ubsag.com/role/ChangesInAccountingPoliciesComparabilityAndAdjustments",
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement",
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows",
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlowsParenthetical",
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquityParenthetical",
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncomeParenthetical",
      "http://www.ubsag.com/role/CurrencyTranslationRates",
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValue",
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueDetail",
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueTable",
      "http://www.ubsag.com/role/DebtIssuedHeldAtAmortizedCost",
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostDetail",
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostTables",
      "http://www.ubsag.com/role/DerivativeInstruments",
      "http://www.ubsag.com/role/DerivativeInstrumentsTables",
      "http://www.ubsag.com/role/DocumentAndEntityInformation",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurement",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementTables",
      "http://www.ubsag.com/role/FVMFairValueMeasurementNarrativeDetail",
      "http://www.ubsag.com/role/FVMValuationAdjustmentsDeferredDay1PLDetail",
      "http://www.ubsag.com/role/FVMValuationAdjustmentsReservesOnTheBalanceSheetDetail",
      "http://www.ubsag.com/role/FairValueMeasurement",
      "http://www.ubsag.com/role/FairValueMeasurementTables",
      "http://www.ubsag.com/role/FundingFromGroupMeasuredAtAmortizedCost",
      "http://www.ubsag.com/role/FundingFromGroupMeasuredAtAmortizedCostDetail",
      "http://www.ubsag.com/role/FundingFromGroupMeasuredAtAmortizedCostTables",
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpenses",
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesDetail",
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesTables",
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMatters",
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersTables",
      "http://www.ubsag.com/role/NetFeeAndCommissionIncome",
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeTables",
      "http://www.ubsag.com/role/NetInterestIncome",
      "http://www.ubsag.com/role/NetInterestIncomeDetail",
      "http://www.ubsag.com/role/NetInterestIncomeTables",
      "http://www.ubsag.com/role/OtherAssetsAndLiabilities",
      "http://www.ubsag.com/role/OtherAssetsAndLiabilitiesTables",
      "http://www.ubsag.com/role/OtherFinancialAssetsMeasuredAtAmortizedCostDetail",
      "http://www.ubsag.com/role/OtherFinancialLiabilitiesDesignatedAtFairValueDetail",
      "http://www.ubsag.com/role/OtherFinancialLiabilitiesMeasuredAtAmortizedCostDetail",
      "http://www.ubsag.com/role/OtherIncome",
      "http://www.ubsag.com/role/OtherIncomeTables",
      "http://www.ubsag.com/role/OtherNonfinancialAssetsDetail",
      "http://www.ubsag.com/role/OtherNonfinancialLiabilitiesDetail",
      "http://www.ubsag.com/role/PersonnelExpenses",
      "http://www.ubsag.com/role/PersonnelExpensesDetail",
      "http://www.ubsag.com/role/PersonnelExpensesTables",
      "http://www.ubsag.com/role/Provisions",
      "http://www.ubsag.com/role/ProvisionsAndContingentLiabilitiesTables",
      "http://www.ubsag.com/role/ProvisionsDetail",
      "http://www.ubsag.com/role/SegmentReporting",
      "http://www.ubsag.com/role/SegmentReportingTables",
      "http://www.ubsag.com/role/SupplementalGuarantorInformationNarrativeDetail",
      "http://www.ubsag.com/role/SupplementalGuarantorInformationRequiredUnderSECRegulations"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entity [Table]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_EntitysTotalForBusinessCombinationsUnderCommonControlMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "EntitysTotalForBusinessCombinationsUnderCommonControlMember",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail",
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity",
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquityParenthetical",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail",
      "http://www.ubsag.com/role/FVMValuationAdjustmentsDeferredDay1PLDetail",
      "http://www.ubsag.com/role/SegmentReportingNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entitys Total For Business Combinations Under Common Control [Member]",
        "terseLabel": "UBS AG (consolidated)"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_EntitysTotalForImpairmentOfFinancialAssetsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "EntitysTotalForImpairmentOfFinancialAssetsMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementChangesToECLModelsScenariosScenarioWeightsAndPostmodelAdjustmentsNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpenseReleaseNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Entitys Total For Impairment Of Financial Assets [Member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for the standard value for the 'Impairment of financial assets' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r193"
     ]
    },
    "ifrs-full_Equity": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "Equity",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_EquityAndLiabilities",
       "weight": 1.0,
       "order": 49.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity",
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquityParenthetical"
     ],
     "lang": {
      "en-us": {
       "role": {
        "periodEndLabel": "Balance",
        "periodStartLabel": "Balance",
        "label": "Equity",
        "totalLabel": "Total equity",
        "verboseLabel": "Total IFRS equity",
        "terseLabel": "Total equity"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of residual interest in the assets of the entity after deducting all its liabilities."
       }
      }
     },
     "auth_ref": [
      "r16",
      "r21",
      "r84",
      "r86",
      "r97",
      "r98",
      "r103"
     ]
    },
    "ifrs-full_EquityAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "EquityAbstract",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail",
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Equity [Abstract]",
        "terseLabel": "Equity"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_EquityAndLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "EquityAndLiabilities",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Equity And Liabilities",
        "totalLabel": "Total liabilities and equity",
        "terseLabel": "Total liabilities and equity"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of the entity's equity and liabilities. [Refer: Equity; Liabilities]"
       }
      }
     },
     "auth_ref": [
      "r16"
     ]
    },
    "ifrs-full_EquityAttributableToOwnersOfParent": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "EquityAttributableToOwnersOfParent",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_Equity",
       "weight": 1.0,
       "order": 47.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Equity Attributable To Owners Of Parent",
        "totalLabel": "Equity attributable to shareholders",
        "terseLabel": "Equity attributable to shareholders",
        "periodEndLabel": "Equity attributable to shareholders at the end of the period",
        "periodStartLabel": "Equity attributable to shareholders at the beginning of the period"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of equity attributable to the owners of the parent. This specifically excludes non-controlling interest."
       }
      }
     },
     "auth_ref": [
      "r15"
     ]
    },
    "ifrs-full_EquityAttributableToOwnersOfParentMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "EquityAttributableToOwnersOfParentMember",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity",
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquityParenthetical",
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Equity Attributable To Owners Of Parent [Member]",
        "terseLabel": "Total equity attributable to shareholders",
        "verboseLabel": "Comprehensive income attributable to shareholders"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for equity attributable to the owners of the parent."
       }
      }
     },
     "auth_ref": [
      "r6"
     ]
    },
    "ubsag_EquityAttributableToOwnersOfParentTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "EquityAttributableToOwnersOfParentTransferredAsOfTheMergerDate",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Equity Attributable To Owners Of Parent Transferred As Of The Merger Date",
        "terseLabel": "Equity attributable to shareholders",
        "documentation": "The amount of equity attributable to the owners of the parent. This specifically excludes non-controlling interest."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_EquityClassifiedAsObligationToPurchaseOwnShares": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "EquityClassifiedAsObligationToPurchaseOwnShares",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Equity Classified As Obligation To Purchase Own Shares",
        "negatedLabel": "Equity classified as obligation to purchase own shares",
        "documentation": "The increase (decrease) in equity resulting from purchase of own shares"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_EquityDividendYieldsMeasurementInputMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "EquityDividendYieldsMeasurementInputMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "terseLabel": "Equity dividend yields",
        "documentation": "This member stands for equity dividend yields used as a measurement input.",
        "label": "Equity Dividend Yields Measurement Input [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_EquityIndexContractsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "EquityIndexContractsMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail",
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "terseLabel": "Equity / index contracts",
        "documentation": "This member relates to equity and/or index contracts.",
        "label": "Equity Index Contracts [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_EquityIndexContractsNetMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "EquityIndexContractsNetMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsSensitivityToChangesInUnobservableInputAssumptionsDetail",
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Equity Index Contracts Net [Member]",
        "terseLabel": "Equity / index derivative contracts, net",
        "documentation": "This member relates to equity and/or index contracts, net.",
        "verboseLabel": "Derivative financial instruments: Equity / index contracts"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_EquityInvestmentsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "EquityInvestmentsMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail",
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail",
      "http://www.ubsag.com/role/FVMLevel3InstrumentsSensitivityToChangesInUnobservableInputAssumptionsDetail",
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Equity Instruments [Member]",
        "terseLabel": "Equity instruments",
        "verboseLabel": "Financial assets and liabilities at fair value held for trading, Financial assets at fair value not held for trading: Equity instruments"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for investments in equity instruments."
       }
      }
     },
     "auth_ref": [
      "r230",
      "r240"
     ]
    },
    "ubsag_EquityLinkedIssuedDebtInstrumentsDesignatedAtFairValueThroughProfitOrLoss": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "EquityLinkedIssuedDebtInstrumentsDesignatedAtFairValueThroughProfitOrLoss",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueDetail": {
       "parentTag": "ubsag_DebtSecuritiesIssuedAtFairValueThroughProfitOrLossDesignatedAsUponInitialRecognition",
       "weight": 1.0,
       "order": 3.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Equity Linked Issued Debt Instruments Designated At Fair Value Through Profit Or Loss",
        "terseLabel": "Equity-linked",
        "documentation": "The amount of equity-linked debt instruments that have been issued and are designated at fair value."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_EquityMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "EquityMember",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity",
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquityParenthetical",
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Equity [Member]",
        "terseLabel": "Total equity"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for the residual interest in the assets of the entity after deducting all its liabilities. It also represents the standard value for the 'Components of equity' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r6"
     ]
    },
    "ifrs-full_EquityPriceRiskMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "EquityPriceRiskMember",
     "presentation": [
      "http://www.ubsag.com/role/DerivativeInstrumentsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Equity Price Risk [Member]",
        "terseLabel": "Equity / index",
        "verboseLabel": "Equity prices"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a component of other price risk that represents the type of risk that the fair value or future cash flows of a financial instrument will fluctuate because of changes in equity prices. [Refer: Financial instruments, class [member]]"
       }
      }
     },
     "auth_ref": [
      "r229",
      "r239"
     ]
    },
    "ubsag_EquityRecognizedInBusinessCombination": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "EquityRecognizedInBusinessCombination",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Equity Recognized In Business Combination",
        "terseLabel": "Equity recognized in a business combination",
        "documentation": "The amount of equity recognized in a business combination."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_EquityToEquityCorrelationMeasurementInputMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "EquityToEquityCorrelationMeasurementInputMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Equity To Equity Correlation Measurement Input [Member]",
        "terseLabel": "Equity-to-equity correlation",
        "documentation": "This member stands for the equity-to-equity correlation used as a measurement input."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_EquityToFXCorrelationMeasurementInputMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "EquityToFXCorrelationMeasurementInputMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Equity To FX Correlation Measurement Input [Member]",
        "terseLabel": "Equity-to-FX correlation",
        "documentation": "This member stands for the equity-to-FX correlation used as a measurement input."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_EquityTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "EquityTransferredAsOfTheMergerDate",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Equity Transferred As Of The Merger Date",
        "terseLabel": "Total equity",
        "documentation": "The amount of residual interest in the assets of the entity after deducting all its liabilities."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_EscrowAccountRelease": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "EscrowAccountRelease",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Escrow Account Release",
        "terseLabel": "Escrow account release",
        "documentation": "The amount released from the escrow account and paid to plaintiffs."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_EstimatedLossesNotCoveredByExistingProvisions": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "EstimatedLossesNotCoveredByExistingProvisions",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Estimated Losses Not Covered By Existing Provisions",
        "terseLabel": "Estimated losses not covered by existing provisions",
        "documentation": "The amount of estimated losses not covered by existing provisions."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_EurozoneMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "EurozoneMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementComparisonOfShockFactorsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Eurozone [Member]",
        "terseLabel": "Eurozone",
        "documentation": "This member relates to Eurozone."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ExchangeDifferencesOnTranslationAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ExchangeDifferencesOnTranslationAbstract",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Exchange Differences On Translation [Abstract]",
        "terseLabel": "Foreign currency translation"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ExpectedCreditLossRate": {
     "xbrltype": "percentItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ExpectedCreditLossRate",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementECLrelevantBalanceSheetAndOffbalanceSheetPositionsIncludingECLAllowancesAndProvisionsNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Expected Credit Loss Rate",
        "terseLabel": "ECL coverage"
       }
      },
      "en": {
       "role": {
        "documentation": "The rate of expected credit losses, calculated as percentage of the gross carrying amount. Expected credit losses are the weighted average of credit losses with the respective risks of a default occurring as the weights."
       }
      }
     },
     "auth_ref": [
      "r228",
      "r237"
     ]
    },
    "ubsag_ExpectedCreditLossesEconomicScenarioAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ExpectedCreditLossesEconomicScenarioAxis",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementComparisonOfShockFactorsDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementEconomicScenariosAndWeightsAppliedDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Expected Credit Losses Economic Scenario [Axis]",
        "documentation": "The axis of a table defines the relationship between the domain members or categories in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_ExpectedCreditLossesEconomicScenarioMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ExpectedCreditLossesEconomicScenarioMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementComparisonOfShockFactorsDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementEconomicScenariosAndWeightsAppliedDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Expected Credit Losses Economic Scenario [Member]",
        "documentation": "This member stands for all economic scenarios used in the calculation of expected credit losses. It also represents the standard value for the 'Expected Credit Losses Economic Scenario' axis if no other member is used."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ExpenseByNature": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ExpenseByNature",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement": {
       "parentTag": "ifrs-full_ProfitLossBeforeTax",
       "weight": -1.0,
       "order": 16.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement",
      "http://www.ubsag.com/role/SegmentReportingDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Expense By Nature",
        "totalLabel": "Operating expenses",
        "terseLabel": "Operating expenses"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of expenses aggregated according to their nature (for example, depreciation, purchases of materials, transport costs, employee benefits and advertising costs), and not reallocated among functions within the entity."
       }
      }
     },
     "auth_ref": [
      "r36"
     ]
    },
    "ubsag_ExpenseOnVariableCompensationFinancialAdvisors": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ExpenseOnVariableCompensationFinancialAdvisors",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/PersonnelExpensesDetail": {
       "parentTag": "ifrs-full_EmployeeBenefitsExpense",
       "weight": 1.0,
       "order": 3.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/PersonnelExpensesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Expense On Variable Compensation Financial Advisors",
        "terseLabel": "of which: variable compensation - financial advisors",
        "documentation": "The amount of variable compensation specifically for financial advisors in the business division Global Wealth Management."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ExplanationOfManagementJudgementsInApplyingEntitysAccountingPoliciesWithSignificantEffectOnRecognisedAmounts": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ExplanationOfManagementJudgementsInApplyingEntitysAccountingPoliciesWithSignificantEffectOnRecognisedAmounts",
     "presentation": [
      "http://www.ubsag.com/role/BasisOfAccountingPolicy"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Explanation Of Management Judgements In Applying Entitys Accounting Policies With Significant Effect On Recognised Amounts",
        "terseLabel": "Critical accounting estimates and judgments"
       }
      },
      "en": {
       "role": {
        "documentation": "The explanation of judgements, apart from those involving estimations, that management has made in the process of applying the entity's accounting policies and that have the most significant effect on the amounts recognised in the financial statements."
       }
      }
     },
     "auth_ref": [
      "r8"
     ]
    },
    "ifrs-full_ExposureToCreditRiskOnLoanCommitmentsAndFinancialGuaranteeContracts": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ExposureToCreditRiskOnLoanCommitmentsAndFinancialGuaranteeContracts",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Exposure To Credit Risk On Loan Commitments And Financial Guarantee Contracts",
        "terseLabel": "Total off-balance sheet financial instruments and other credit lines",
        "verboseLabel": "Total exposure"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of the exposure to credit risk on loan commitments and financial guarantee contracts. [Refer: Loan commitments [member]; Financial guarantee contracts [member]; Credit risk [member]]"
       }
      }
     },
     "auth_ref": [
      "r151",
      "r152",
      "r158"
     ]
    },
    "ubsag_FairValueMeasurementAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "FairValueMeasurementAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Fair Value Measurement [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_FairValueMeasurementLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "FairValueMeasurementLineItems",
     "presentation": [
      "http://www.ubsag.com/role/FairValueMeasurementTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Fair Value Measurement [Line Items]",
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with domain members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_FairValueMeasurementWithUnobservableInputsReconciliationRecurringBasisAssetForeignCurrencyTranslationImpact": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "FairValueMeasurementWithUnobservableInputsReconciliationRecurringBasisAssetForeignCurrencyTranslationImpact",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Fair Value Measurement With Unobservable Inputs Reconciliation Recurring Basis Asset Foreign Currency Translation Impact",
        "terseLabel": "Foreign currency translation",
        "documentation": "This element represents the impact of foreign currency translation on the fair value of assets which is measured on a recurring basis using significant unobservable inputs reconciliation (Level 3)."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_FairValueMeasurementWithUnobservableInputsReconciliationRecurringBasisLiabilityForeignCurrencyTranslationImpact": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "FairValueMeasurementWithUnobservableInputsReconciliationRecurringBasisLiabilityForeignCurrencyTranslationImpact",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Fair Value Measurement With Unobservable Inputs Reconciliation Recurring Basis Liability Foreign Currency Translation Impact",
        "terseLabel": "Foreign currency translation",
        "documentation": "This element represents the impact of foreign currency translation on the fair value of liability which is measured on a recurring basis using significant unobservable inputs reconciliation (Level 3)."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_FairValueOfDerivativeLiabilityAccountedForToRecogniseFundingObligation": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "FairValueOfDerivativeLiabilityAccountedForToRecogniseFundingObligation",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersDetail",
      "http://www.ubsag.com/role/ProvisionsAdditionalInformationDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Fair Value Of Derivative Liability Accounted For To Recognise Funding Obligation",
        "terseLabel": "Fair value of a derivative liability accounted for to recognise a funding obligation",
        "documentation": "The amount of a derivative liability at fair value accounted for to recognise entity's funding obligation."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_FairValueOfFinancialAssetsReclassifiedOutOfFairValueThroughOtherComprehensiveIncomeCategoryIntoAmortisedCostCategory": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FairValueOfFinancialAssetsReclassifiedOutOfFairValueThroughOtherComprehensiveIncomeCategoryIntoAmortisedCostCategory",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/ReclassificationOfFinancialAssetsNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Fair Value Of Financial Assets Reclassified Out Of Fair Value Through Other Comprehensive Income Category Into Amortised Cost Category",
        "terseLabel": "Fair value of financial assets reclassified out of fair value through other comprehensive income category into amortised cost category"
       }
      },
      "en": {
       "role": {
        "documentation": "The fair value of financial assets reclassified out of the fair value other comprehensive income category so that they are measured at amortised cost. [Refer: Financial assets]"
       }
      }
     },
     "auth_ref": [
      "r134"
     ]
    },
    "ifrs-full_FeeAndCommissionExpense": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FeeAndCommissionExpense",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement": {
       "parentTag": "ifrs-full_FeeAndCommissionIncomeExpense",
       "weight": -1.0,
       "order": 8.0
      },
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail": {
       "parentTag": "ifrs-full_FeeAndCommissionIncomeExpense",
       "weight": -1.0,
       "order": 9.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement",
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Fee And Commission Expense",
        "totalLabel": "Total fee and commission expense",
        "negatedLabel": "Fee and commission expense",
        "terseLabel": "Fee and commission expense"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of expense relating to fees and commissions."
       }
      }
     },
     "auth_ref": [
      "r252"
     ]
    },
    "ifrs-full_FeeAndCommissionIncome": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FeeAndCommissionIncome",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement": {
       "parentTag": "ifrs-full_FeeAndCommissionIncomeExpense",
       "weight": 1.0,
       "order": 7.0
      },
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail": {
       "parentTag": "ifrs-full_FeeAndCommissionIncomeExpense",
       "weight": 1.0,
       "order": 8.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement",
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Fee And Commission Income",
        "totalLabel": "Total fee and commission income",
        "terseLabel": "Fee and commission income"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of income relating to fees and commissions."
       }
      }
     },
     "auth_ref": [
      "r252"
     ]
    },
    "ifrs-full_FeeAndCommissionIncomeExpense": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FeeAndCommissionIncomeExpense",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement": {
       "parentTag": "ifrs-full_RevenueAndOperatingIncome",
       "weight": 1.0,
       "order": 9.0
      },
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement",
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "totalLabel": "Net fee and commission income",
        "terseLabel": "Net fee and commission income",
        "label": "Fee And Commission Income Expense"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of income or expense relating to fees and commissions."
       }
      }
     },
     "auth_ref": [
      "r252"
     ]
    },
    "ifrs-full_FeeAndCommissionIncomeExpenseAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FeeAndCommissionIncomeExpenseAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Fee And Commission Income Expense [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_FinanceLeaseReceivables": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FinanceLeaseReceivables",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/OtherFinancialAssetsMeasuredAtAmortizedCostDetail": {
       "parentTag": "ubsag_OtherFinancialAssetsAtAmortisedCost",
       "weight": 1.0,
       "order": 5.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherFinancialAssetsMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Finance Lease Receivables",
        "terseLabel": "Finance lease receivables"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of receivables related to finance leases."
       }
      }
     },
     "auth_ref": [
      "r249"
     ]
    },
    "ubsag_FinancialAdvisorCompensationPlansLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "FinancialAdvisorCompensationPlansLiabilities",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/OtherNonfinancialLiabilitiesDetail": {
       "parentTag": "ubsag_CompensationrelatedLiabilities",
       "weight": 1.0,
       "order": 4.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherNonfinancialLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Advisor Compensation Plans Liabilities",
        "terseLabel": "of which: financial advisor compensation plans",
        "documentation": "The amount of compensation-related liabilities related to financial advisor compensation plans."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_FinancialAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FinancialAssets",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Assets",
        "terseLabel": "Financial assets",
        "totalLabel": "Total",
        "verboseLabel": "ECL provision",
        "periodStartLabel": "Balance as of 1.1.2018",
        "periodEndLabel": "Balance as of 31.12.2018"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of assets that are: (a) cash; (b) an equity instrument of another entity; (c) a contractual right: (i) to receive cash or another financial asset from another entity; or (ii) to exchange financial assets or financial liabilities with another entity under conditions that are potentially favourable to the entity; or (d) a contract that will, or may be, settled in the entity\u2019s own equity instruments and is: (i) a non-derivative for which the entity is, or may be, obliged to receive a variable number of the entity\u2019s own equity instruments; or (ii) a derivative that will, or may be, settled other than by the exchange of a fixed amount of cash or another financial asset for a fixed number of the entity\u2019s own equity instruments. For this purpose the entity\u2019s own equity instruments do not include puttable financial instruments classified as equity instruments in accordance with paragraphs 16A-16B of IAS 32, instruments that impose on the entity an obligation to deliver to another party a pro rata share of the net assets of the entity only on liquidation and are classified as equity instruments in accordance with paragraphs 16C-16D of IAS 32, or instruments that are contracts for the future receipt or delivery of the entity\u2019s own equity instruments. [Refer: Financial instruments, class [member]; Financial liabilities]"
       }
      }
     },
     "auth_ref": [
      "r143",
      "r151",
      "r152",
      "r158",
      "r228"
     ]
    },
    "ubsag_FinancialAssetsAndExposureToCreditRiskOnLoanCommitmentsAndFinancialGuaranteeContractsInCoreLoanPortfolio": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "FinancialAssetsAndExposureToCreditRiskOnLoanCommitmentsAndFinancialGuaranteeContractsInCoreLoanPortfolio",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Assets And Exposure To Credit Risk On Loan Commitments And Financial Guarantee Contracts In Core Loan Portfolio",
        "terseLabel": "Total on- and off-balance sheet",
        "documentation": "The total amount of financial assets, loan commitments and financial guarantee contracts in on- and off-balance sheet loan portfolio, in scope of expected credit loss measurement."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_FinancialAssetsAtAmortisedCost": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FinancialAssetsAtAmortisedCost",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_Assets",
       "weight": 1.0,
       "order": 9.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Assets At Amortised Cost",
        "totalLabel": "Total financial assets measured at amortized cost",
        "terseLabel": "Total financial assets measured at amortized cost"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of financial assets at amortised cost. The amortised cost is the amount at which financial assets are measured at initial recognition minus principal repayments, plus or minus the cumulative amortisation using the effective interest method of any difference between that initial amount and the maturity amount, and adjusted for any impairment. [Refer: Financial assets]"
       }
      }
     },
     "auth_ref": [
      "r163"
     ]
    },
    "ifrs-full_FinancialAssetsAtAmortisedCostMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FinancialAssetsAtAmortisedCostMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementECLrelevantBalanceSheetAndOffbalanceSheetPositionsIncludingECLAllowancesAndProvisionsNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Assets At Amortised Cost [Member]",
        "terseLabel": "Total financial assets measured at amortized cost",
        "verboseLabel": "Total credit-impaired financial assets measured at amortized cost"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for the financial assets measured at amortised cost class. [Refer: Financial assets at amortised cost]"
       }
      }
     },
     "auth_ref": [
      "r167"
     ]
    },
    "ubsag_FinancialAssetsAtAmortisedCostTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "FinancialAssetsAtAmortisedCostTransferredAsOfTheMergerDate",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Assets At Amortised Cost Transferred As Of The Merger Date",
        "terseLabel": "Total financial assets measured at amortized cost",
        "documentation": "The amount of financial assets at amortised cost. The amortised cost is the amount at which financial assets are measured at initial recognition minus principal repayments, plus or minus the cumulative amortisation using the effective interest method of any difference between that initial amount and the maturity amount, and adjusted for any impairment. [Refer: Financial assets]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_FinancialAssetsAtFairValue": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FinancialAssetsAtFairValue",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Assets At Fair Value",
        "periodStartLabel": "Balance at the beginning of the period",
        "periodEndLabel": "Balance at the end of period",
        "terseLabel": "Financial assets measured at fair value"
       }
      },
      "en": {
       "role": {
        "documentation": "The fair value of financial assets. [Refer: At fair value [member]; Financial assets]"
       }
      }
     },
     "auth_ref": [
      "r143"
     ]
    },
    "ifrs-full_FinancialAssetsAtFairValueThroughProfitOrLoss": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FinancialAssetsAtFairValueThroughProfitOrLoss",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_Assets",
       "weight": 1.0,
       "order": 15.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet"
     ],
     "lang": {
      "en-us": {
       "role": {
        "totalLabel": "Total financial assets measured at fair value through profit or loss",
        "label": "Financial Assets At Fair Value Through Profit Or Loss",
        "terseLabel": "Total financial assets measured at fair value through profit or loss"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of financial assets that are measured at fair value and for which gains (losses) are recognised in profit or loss. A financial asset shall be measured at fair value through profit or loss unless it is measured at amortised cost or at fair value through other comprehensive income. A gain (loss) on a financial asset measured at fair value shall be recognised in profit or loss unless it is part of a hedging relationship, it is an investment in an equity instrument for which the entity has elected to present gains and losses in other comprehensive income or it is a financial asset measured at fair value through other comprehensive income. [Refer: At fair value [member]; Financial assets]"
       }
      }
     },
     "auth_ref": [
      "r161"
     ]
    },
    "ifrs-full_FinancialAssetsAtFairValueThroughProfitOrLossClassifiedAsHeldForTrading": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FinancialAssetsAtFairValueThroughProfitOrLossClassifiedAsHeldForTrading",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail": {
       "parentTag": "ubsag_AssetsMeasuredAtFairValue",
       "weight": 1.0,
       "order": 2.0
      },
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_FinancialAssetsAtFairValueThroughProfitOrLoss",
       "weight": 1.0,
       "order": 10.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "totalLabel": "Financial assets at fair value through profit or loss classified as held for trading",
        "verboseLabel": "of which: financial assets at fair value held for trading",
        "terseLabel": "Financial assets at fair value held for trading",
        "label": "Financial Assets At Fair Value Through Profit Or Loss Classified As Held For Trading"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of financial assets at fair value through profit or loss classified as held for trading. A financial asset is classified as held for trading if: (a) it is acquired principally for the purpose of selling it in the near term; (b) on initial recognition it is part of a portfolio of identified financial instruments that are managed together and for which there is evidence of a recent actual pattern of short-term profit-taking; or (c) it is a derivative (except for a derivative that is a financial guarantee contract or a designated and effective hedging instrument). [Refer: At fair value [member]; Financial assets at fair value through profit or loss]"
       }
      }
     },
     "auth_ref": [
      "r249"
     ]
    },
    "ifrs-full_FinancialAssetsAtFairValueThroughProfitOrLossClassifiedAsHeldForTradingCategoryMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FinancialAssetsAtFairValueThroughProfitOrLossClassifiedAsHeldForTradingCategoryMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Assets At Fair Value Through Profit Or Loss Classified As Held For Trading Category [Member]",
        "terseLabel": "Financial assets at fair value held for trading"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for the financial assets at fair value through profit or loss classified as held for trading category. [Refer: Financial assets at fair value through profit or loss, classified as held for trading]"
       }
      }
     },
     "auth_ref": [
      "r194"
     ]
    },
    "ubsag_FinancialAssetsAtFairValueThroughProfitOrLossClassifiedAsHeldForTradingTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "FinancialAssetsAtFairValueThroughProfitOrLossClassifiedAsHeldForTradingTransferredAsOfTheMergerDate",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Assets At Fair Value Through Profit Or Loss Classified As Held For Trading Transferred As Of The Merger Date",
        "terseLabel": "Financial assets at fair value held for trading",
        "documentation": "The amount of financial assets at fair value through profit or loss classified as held for trading. A financial asset is classified as held for trading if: (a) it is acquired principally for the purpose of selling it in the near term; (b) on initial recognition it is part of a portfolio of identified financial instruments that are managed together and for which there is evidence of a recent actual pattern of short-term profit-taking; or (c) it is a derivative (except for a derivative that is a financial guarantee contract or a designated and effective hedging instrument). [Refer: At fair value [member]; Financial assets at fair value through profit or loss]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_FinancialAssetsAtFairValueThroughProfitOrLossMandatorilyMeasuredAtFairValue": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FinancialAssetsAtFairValueThroughProfitOrLossMandatorilyMeasuredAtFairValue",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail": {
       "parentTag": "ubsag_AssetsMeasuredAtFairValue",
       "weight": 1.0,
       "order": 5.0
      },
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_FinancialAssetsAtFairValueThroughProfitOrLoss",
       "weight": 1.0,
       "order": 14.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Assets At Fair Value Through Profit Or Loss Mandatorily Measured At Fair Value",
        "terseLabel": "Financial assets at fair value not held for trading",
        "verboseLabel": "of which: financial assets at fair value not held for trading"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of financial assets mandatorily measured at fair value through profit or loss in accordance with IFRS 9. [Refer: Financial assets at fair value through profit or loss]"
       }
      }
     },
     "auth_ref": [
      "r161"
     ]
    },
    "ifrs-full_FinancialAssetsAtFairValueThroughProfitOrLossMandatorilyMeasuredAtFairValueCategoryMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FinancialAssetsAtFairValueThroughProfitOrLossMandatorilyMeasuredAtFairValueCategoryMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Assets At Fair Value Through Profit Or Loss Mandatorily Measured At Fair Value Category [Member]",
        "terseLabel": "Financial assets at fair value not held for trading"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for the financial assets mandatorily measured at fair value through profit or loss category. [Refer: Financial assets at fair value through profit or loss, mandatorily measured at fair value]"
       }
      }
     },
     "auth_ref": [
      "r161"
     ]
    },
    "ubsag_FinancialAssetsAtFairValueThroughProfitOrLossMandatorilyMeasuredAtFairValueTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "FinancialAssetsAtFairValueThroughProfitOrLossMandatorilyMeasuredAtFairValueTransferredAsOfTheMergerDate",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Assets At Fair Value Through Profit Or Loss Mandatorily Measured At Fair Value Transferred As Of The Merger Date",
        "terseLabel": "Financial assets at fair value not held for trading",
        "documentation": "The amount of financial assets mandatorily measured at fair value through profit or loss in accordance with IFRS 9. [Refer: Financial assets at fair value through profit or loss]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_FinancialAssetsAtFairValueThroughProfitOrLossTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "FinancialAssetsAtFairValueThroughProfitOrLossTransferredAsOfTheMergerDate",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Assets At Fair Value Through Profit Or Loss Transferred As Of The Merger Date",
        "terseLabel": "Total financial assets measured at fair value through profit or loss",
        "documentation": "The amount of financial assets that are measured at fair value and for which gains (losses) are recognised in profit or loss. A financial asset shall be measured at fair value through profit or loss unless it is measured at amortised cost or at fair value through other comprehensive income. A gain (loss) on a financial asset measured at fair value shall be recognised in profit or loss unless it is part of a hedging relationship, it is an investment in an equity instrument for which the entity has elected to present gains and losses in other comprehensive income or it is a financial asset measured at fair value through other comprehensive income. [Refer: At fair value [member]; Financial assets]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_FinancialAssetsCategoryMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FinancialAssetsCategoryMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Assets Category [Member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for aggregated categories of financial assets. It also represents the standard value for the 'Categories of financial assets' axis if no other member is used. [Refer: Financial assets]"
       }
      }
     },
     "auth_ref": [
      "r166"
     ]
    },
    "ubsag_FinancialAssetsForUnitLinkedInvestmentContractsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "FinancialAssetsForUnitLinkedInvestmentContractsMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "This member relates to financial assets for unit linked investment contracts.",
        "terseLabel": "Financial assets for unit-linked investment contracts",
        "label": "Financial Assets For Unit Linked Investment Contracts [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_FinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncome": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncome",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail": {
       "parentTag": "ubsag_AssetsMeasuredAtFairValue",
       "weight": 1.0,
       "order": 6.0
      },
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_Assets",
       "weight": 1.0,
       "order": 16.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Assets Measured At Fair Value Through Other Comprehensive Income",
        "terseLabel": "Financial assets measured at fair value through other comprehensive income",
        "totalLabel": "Total financial assets measured at fair value through other comprehensive income"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of financial assets that are measured at fair value through other comprehensive income. A financial asset shall be measured at fair value through other comprehensive income if both of the following conditions are met: (a) the financial asset is held within a business model whose objective is achieved by both collecting contractual cash flows and selling financial assets and (b) the contractual terms of the financial asset give rise on specified dates to cash flows that are solely payments of principal and interest on the principal amount outstanding. [Refer: At fair value [member]; Financial assets]"
       }
      }
     },
     "auth_ref": [
      "r165"
     ]
    },
    "ifrs-full_FinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncomeAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncomeAbstract",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Assets Measured At Fair Value Through Other Comprehensive Income [Abstract]",
        "terseLabel": "Financial assets measured at fair value through other comprehensive income"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_FinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncomeCategoryMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncomeCategoryMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Assets Measured At Fair Value Through Other Comprehensive Income Category [Member]",
        "terseLabel": "Financial assets measured at fair value through other comprehensive income"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for the financial assets at fair value through other comprehensive income category. [Refer: Financial assets measured at fair value through other comprehensive income]"
       }
      }
     },
     "auth_ref": [
      "r165"
     ]
    },
    "ubsag_FinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncomeTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "FinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncomeTransferredAsOfTheMergerDate",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Assets Measured At Fair Value Through Other Comprehensive Income Transferred As Of The Merger Date",
        "terseLabel": "Financial assets measured at fair value through other comprehensive income",
        "documentation": "The amount of financial assets that are measured at fair value through other comprehensive income. A financial asset shall be measured at fair value through other comprehensive income if both of the following conditions are met: (a) the financial asset is held within a business model whose objective is achieved by both collecting contractual cash flows and selling financial assets and (b) the contractual terms of the financial asset give rise on specified dates to cash flows that are solely payments of principal and interest on the principal amount outstanding. [Refer: At fair value [member]; Financial assets]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_FinancialAssetsTypeMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FinancialAssetsTypeMember",
     "presentation": [
      "http://www.ubsag.com/role/OffsettingFinancialAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Assets Type [Member]",
        "terseLabel": "Total assets"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for aggregated types of financial assets. It also represents the standard value for the 'Types of financial assets' axis if no other member is used. [Refer: Financial assets]"
       }
      }
     },
     "auth_ref": [
      "r168",
      "r169"
     ]
    },
    "ifrs-full_FinancialGuaranteeContractsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FinancialGuaranteeContractsMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Guarantee Contracts [Member]",
        "terseLabel": "Guarantees"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for contracts that require the issuer to make specified payments to reimburse the holder for a loss it incurs because a specified debtor fails to make payment when due in accordance with the original or modified terms of a debt instrument."
       }
      }
     },
     "auth_ref": [
      "r158",
      "r170"
     ]
    },
    "ubsag_FinancialInstrumentAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "FinancialInstrumentAxis",
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail",
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail",
      "http://www.ubsag.com/role/FVMLevel3InstrumentsSensitivityToChangesInUnobservableInputAssumptionsDetail",
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Instrument [Axis]",
        "documentation": "The axis of a table defines the relationship between the domain members or categories in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_FinancialInstrumentsCreditimpairedAfterPurchaseOrOriginationMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FinancialInstrumentsCreditimpairedAfterPurchaseOrOriginationMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpenseReleaseNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpensereleaseDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Instruments Credit impaired After Purchase Or Origination [Member]",
        "verboseLabel": "Stage 3",
        "terseLabel": "Stage 3 positions"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for financial instruments that were credit-impaired after purchase or origination. [Refer: Financial instruments credit-impaired [member]]"
       }
      }
     },
     "auth_ref": [
      "r148",
      "r155"
     ]
    },
    "ifrs-full_FinancialInstrumentsCreditimpairedMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FinancialInstrumentsCreditimpairedMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpenseReleaseNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Instruments Credit-impaired [Member]",
        "terseLabel": "Credit-impaired (stage 3 and purchased credit-impaired) positions"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for financial instruments that are credit-impaired. [Refer: Credit impairment of financial instruments [member]]"
       }
      }
     },
     "auth_ref": [
      "r151",
      "r158"
     ]
    },
    "ifrs-full_FinancialInstrumentsNotCreditimpairedMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FinancialInstrumentsNotCreditimpairedMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementChangesToECLModelsScenariosScenarioWeightsAndPostmodelAdjustmentsNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpenseReleaseNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpensereleaseDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementECLrelevantBalanceSheetAndOffbalanceSheetPositionsIncludingECLAllowancesAndProvisionsNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Instruments Not Credit-impaired [Member]",
        "verboseLabel": "Stages 1 and 2",
        "terseLabel": "Stage 1 and 2 positions"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for financial instruments that are not credit-impaired. [Refer: Credit impairment of financial instruments [member]]"
       }
      }
     },
     "auth_ref": [
      "r151",
      "r158"
     ]
    },
    "ifrs-full_FinancialInstrumentsPurchasedOrOriginatedCreditimpairedMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FinancialInstrumentsPurchasedOrOriginatedCreditimpairedMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpenseReleaseNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpensereleaseDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Instruments Purchased Or Originated Credit Impaired [Member]",
        "terseLabel": "Purchased credit-impaired (PCI)",
        "verboseLabel": "Purchased"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for financial instruments that were purchased or originated as credit-impaired. [Refer: Financial instruments credit-impaired [member]]"
       }
      }
     },
     "auth_ref": [
      "r150",
      "r157"
     ]
    },
    "ifrs-full_FinancialInstrumentsSubjectToEnforceableMasterNettingArrangementOrSimilarAgreementNotSetOffAgainstFinancialAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FinancialInstrumentsSubjectToEnforceableMasterNettingArrangementOrSimilarAgreementNotSetOffAgainstFinancialAssets",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/OffsettingFinancialAssetsDetail": {
       "parentTag": "ifrs-full_AmountsSubjectToEnforceableMasterNettingArrangementOrSimilarAgreementNotSetOffAgainstFinancialAssets",
       "weight": 1.0,
       "order": 4.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OffsettingFinancialAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Instruments Subject To Enforceable Master Netting Arrangement Or Similar Agreement Not Set Off Against Financial Assets",
        "negatedLabel": "of which: netting of recognized financial liabilities"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of financial instruments subject to an enforceable master netting arrangement or similar agreement that are not set off against financial assets. [Refer: Financial assets]"
       }
      }
     },
     "auth_ref": [
      "r224",
      "r241"
     ]
    },
    "ifrs-full_FinancialInstrumentsSubjectToEnforceableMasterNettingArrangementOrSimilarAgreementNotSetOffAgainstFinancialLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FinancialInstrumentsSubjectToEnforceableMasterNettingArrangementOrSimilarAgreementNotSetOffAgainstFinancialLiabilities",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/OffsettingFinancialLiabilitiesDetail": {
       "parentTag": "ifrs-full_AmountsSubjectToEnforceableMasterNettingArrangementOrSimilarAgreementNotSetOffAgainstFinancialLiabilities",
       "weight": 1.0,
       "order": 4.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OffsettingFinancialLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Instruments Subject To Enforceable Master Netting Arrangement Or Similar Agreement Not Set Off Against Financial Liabilities",
        "negatedLabel": "of which: netting of recognized financial assets"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of financial instruments subject to an enforceable master netting arrangement or similar agreement that are not set off against financial liabilities. [Refer: Financial liabilities]"
       }
      }
     },
     "auth_ref": [
      "r224",
      "r241"
     ]
    },
    "ubsag_FinancialIntermediariesAndHedgeFundsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "FinancialIntermediariesAndHedgeFundsMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Intermediaries And Hedge Funds [Member]",
        "terseLabel": "Financial intermediaries and hedge funds",
        "documentation": "This member relates to financial intermediaries and hedge funds.",
        "verboseLabel": "of which: Financial intermediaries and hedge funds"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_FinancialLiabilitiesAtAmortisedCost": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FinancialLiabilitiesAtAmortisedCost",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_Liabilities",
       "weight": 1.0,
       "order": 31.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Liabilities At Amortised Cost",
        "totalLabel": "Total financial liabilities measured at amortized cost",
        "terseLabel": "Total financial liabilities measured at amortized cost"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of financial liabilities at amortised cost. The amortised cost is the amount at which financial liabilities are measured at initial recognition minus principal repayments, plus or minus the cumulative amortisation using the effective interest method of any difference between that initial amount and the maturity amount. [Refer: Financial liabilities]"
       }
      }
     },
     "auth_ref": [
      "r164"
     ]
    },
    "ubsag_FinancialLiabilitiesAtAmortisedCostTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "FinancialLiabilitiesAtAmortisedCostTransferredAsOfTheMergerDate",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Liabilities At Amortised Cost Transferred As Of The Merger Date",
        "terseLabel": "Total financial liabilities measured at amortized cost",
        "documentation": "The amount of financial liabilities at amortised cost. The amortised cost is the amount at which financial liabilities are measured at initial recognition minus principal repayments, plus or minus the cumulative amortisation using the effective interest method of any difference between that initial amount and the maturity amount. [Refer: Financial liabilities]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_FinancialLiabilitiesAtFairValue": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FinancialLiabilitiesAtFairValue",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Liabilities At Fair Value",
        "terseLabel": "Financial liabilities measured at fair value",
        "periodStartLabel": "Balance at the beginning of the period",
        "periodEndLabel": "Balance at the end of period"
       }
      },
      "en": {
       "role": {
        "documentation": "The fair value of financial liabilities. [Refer: At fair value [member]; Financial liabilities]"
       }
      }
     },
     "auth_ref": [
      "r143"
     ]
    },
    "ifrs-full_FinancialLiabilitiesAtFairValueThroughProfitOrLoss": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FinancialLiabilitiesAtFairValueThroughProfitOrLoss",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_Liabilities",
       "weight": 1.0,
       "order": 37.0
      },
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Liabilities At Fair Value Through Profit Or Loss",
        "totalLabel": "Total financial liabilities measured at fair value through profit or loss",
        "terseLabel": "Total financial liabilities measured at fair value through profit or loss"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of financial liabilities that meet either of the following conditions: (a) they meet the definition of held for trading; or (b) upon initial recognition they are designated by the entity as at fair value through profit or loss. An entity may use this designation only when permitted by paragraph 4.3.5 of IFRS 9 (embedded derivatives) or when doing so results in more relevant information, because either: (a) it eliminates or significantly reduces a measurement or recognition inconsistency (sometimes referred to as \u2018an accounting mismatch\u2019) that would otherwise arise from measuring assets or liabilities or recognising the gains and losses on them on different bases; or (b) a group of financial liabilities or financial assets and financial liabilities is managed and its performance is evaluated on a fair value basis, in accordance with a documented risk management or investment strategy, and information about the group is provided internally on that basis to the entity\u2019s key management personnel (as defined in IAS 24). [Refer: At fair value [member]; Key management personnel of entity or parent [member]; Derivatives [member]; Financial assets; Financial liabilities]"
       }
      }
     },
     "auth_ref": [
      "r162"
     ]
    },
    "ifrs-full_FinancialLiabilitiesAtFairValueThroughProfitOrLossClassifiedAsHeldForTrading": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FinancialLiabilitiesAtFairValueThroughProfitOrLossClassifiedAsHeldForTrading",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail": {
       "parentTag": "ifrs-full_FinancialLiabilitiesAtFairValueThroughProfitOrLoss",
       "weight": 1.0,
       "order": 2.0
      },
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_FinancialLiabilitiesAtFairValueThroughProfitOrLoss",
       "weight": 1.0,
       "order": 32.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Liabilities At Fair Value Through Profit Or Loss Classified As Held For Trading",
        "totalLabel": "Total",
        "terseLabel": "Financial liabilities at fair value held for trading",
        "verboseLabel": "Financial liabilities at fair value held for trading (formerly Trading portfolio liabilities)"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of financial liabilities at fair value through profit or loss that meet the definition of held for trading. A financial liability is classified as held for trading if: (a) it is acquired or incurred principally for the purpose of selling or repurchasing it in the near term; (b) on initial recognition it is part of a portfolio of identified financial instruments that are managed together and for which there is evidence of a recent actual pattern of short-term profit-taking; or (c) it is a derivative (except for a derivative that is a financial guarantee contract or a designated and effective hedging instrument). [Refer: Financial liabilities at fair value through profit or loss]"
       }
      }
     },
     "auth_ref": [
      "r162"
     ]
    },
    "ubsag_FinancialLiabilitiesAtFairValueThroughProfitOrLossClassifiedAsHeldForTradingTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "FinancialLiabilitiesAtFairValueThroughProfitOrLossClassifiedAsHeldForTradingTransferredAsOfTheMergerDate",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Liabilities At Fair Value Through Profit Or Loss Classified As Held For Trading Transferred As Of The Merger Date",
        "terseLabel": "Financial liabilities at fair value held for trading",
        "documentation": "The amount of financial liabilities at fair value through profit or loss that meet the definition of held for trading. A financial liability is classified as held for trading if: (a) it is acquired or incurred principally for the purpose of selling or repurchasing it in the near term; (b) on initial recognition it is part of a portfolio of identified financial instruments that are managed together and for which there is evidence of a recent actual pattern of short-term profit-taking; or (c) it is a derivative (except for a derivative that is a financial guarantee contract or a designated and effective hedging instrument). [Refer: Financial liabilities at fair value through profit or loss]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_FinancialLiabilitiesAtFairValueThroughProfitOrLossTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "FinancialLiabilitiesAtFairValueThroughProfitOrLossTransferredAsOfTheMergerDate",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Liabilities At Fair Value Through Profit Or Loss Transferred As Of The Merger Date",
        "terseLabel": "Total financial liabilities measured at fair value through profit or loss",
        "documentation": "The amount of financial liabilities at fair value through profit or loss as of acquisition date"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_FinancialLiabilitiesCategoryMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FinancialLiabilitiesCategoryMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Liabilities Category [Member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for aggregated categories of financial liabilities. It also represents the standard value for the 'Categories of financial liabilities' axis if no other member is used. [Refer: Financial assets]"
       }
      }
     },
     "auth_ref": [
      "r166"
     ]
    },
    "ifrs-full_FinancialLiabilitiesTypeMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "FinancialLiabilitiesTypeMember",
     "presentation": [
      "http://www.ubsag.com/role/OffsettingFinancialLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Financial Liabilities Type [Member]",
        "terseLabel": "Total liabilities"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for aggregated types of financial liabilities. It also represents the standard value for the 'Types of financial liabilities' axis if no other member is used. [Refer: Financial assets]"
       }
      }
     },
     "auth_ref": [
      "r168",
      "r169"
     ]
    },
    "ubsag_FineDecisionEuropeanCommission": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "FineDecisionEuropeanCommission",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Fine Decision European Commission",
        "terseLabel": "Fine provided in announcement of the European Commission",
        "documentation": "Fine provided in announcement of the European Commission."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_FineDecisionFrenchCourt": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "FineDecisionFrenchCourt",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Fine Decision French Court",
        "terseLabel": "Fine decision French Court",
        "documentation": "Fine decision French Court."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_FineDecisionFrenchCourtOfAppeal": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "FineDecisionFrenchCourtOfAppeal",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Fine Decision French Court Of Appeal",
        "terseLabel": "Fine decision French Court of Appeal",
        "documentation": "Fine decision French Court of Appeal."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_FineDecisionSwissFederalCriminalCourt": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "FineDecisionSwissFederalCriminalCourt",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Fine Decision Swiss Federal Criminal Court",
        "terseLabel": "Fine decision Swiss Federal Criminal Court",
        "documentation": "Fine decision Swiss Federal Criminal Court."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_FineOverturnedFrenchSupremeCourt": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "FineOverturnedFrenchSupremeCourt",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Fine Overturned French Supreme Court",
        "terseLabel": "Fine overturned French Supreme Court",
        "documentation": "Fine decision overturned in the verdict of the French Supreme Court."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_FixedRateIssuedDebtInstrumentsDesignatedAtFairValueThroughProfitOrLoss": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "FixedRateIssuedDebtInstrumentsDesignatedAtFairValueThroughProfitOrLoss",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueDetail": {
       "parentTag": "ubsag_DebtSecuritiesIssuedAtFairValueThroughProfitOrLossDesignatedAsUponInitialRecognition",
       "weight": 1.0,
       "order": 6.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Fixed Rate Issued Debt Instruments Designated At Fair Value Through Profit Or Loss",
        "terseLabel": "Fixed-rate",
        "documentation": "The amount of fixed-rate debt instruments that have been issued and are designated at fair value."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_ForeignExchangeContractsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ForeignExchangeContractsMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail",
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Foreign Exchange Contracts [Member]",
        "terseLabel": "Foreign exchange",
        "documentation": "This member relates to foreign exchange contracts."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_ForeignExchangeContractsNetMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ForeignExchangeContractsNetMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsSensitivityToChangesInUnobservableInputAssumptionsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Foreign Exchange Contracts Net [Member]",
        "terseLabel": "Foreign exchange derivative contracts, net",
        "documentation": "This member relates to foreign exchange contracts, net."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ForeignExchangeRatesAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ForeignExchangeRatesAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Foreign Exchange Rates [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_ForeignExchangeRatesDetailsAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ForeignExchangeRatesDetailsAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Foreign Exchange Rates Details [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_ForeignExchangeRatesLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ForeignExchangeRatesLineItems",
     "presentation": [
      "http://www.ubsag.com/role/BasisOfAccountingCurrencyTranslationRatesDetail",
      "http://www.ubsag.com/role/BasisOfAccountingTables",
      "http://www.ubsag.com/role/CurrencyTranslationRates"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Foreign Exchange Rates [Line Items]",
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with domain members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_ForeignExchangeRatesTable": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ForeignExchangeRatesTable",
     "presentation": [
      "http://www.ubsag.com/role/BasisOfAccountingCurrencyTranslationRatesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Foreign Exchange Rates [Table]",
        "documentation": "Schedule disclosing information related to details of foreign exchange rates used."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_ForeignExchangeTradingMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ForeignExchangeTradingMember",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "terseLabel": "Rates-related matters | Foreign exchange trading business",
        "label": "Foreign Exchange Trading [Member]",
        "documentation": "This member refers to practices in foreign exchange trading business."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_ForexRelatedCivilLitigationMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ForexRelatedCivilLitigationMember",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Forex Related Civil Litigation [Member]",
        "terseLabel": "Foreign exchange, LIBOR and benchmark rates, and other trading practices - Foreign exchange-related civil litigation | Claims under the Commodity Exchange Act",
        "documentation": "This member refers to settlement of antitrust and Commodity Exchange Act claims related to foreign exchange."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_ForexRelatedGovernmentSponsoredEntitiesBondsMattersMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ForexRelatedGovernmentSponsoredEntitiesBondsMattersMember",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Forex Related Government Sponsored Entities Bonds Matters [Member]",
        "terseLabel": "Foreign exchange, LIBOR and benchmark rates, and other trading practices - Government Sponsored Entities Bonds matters",
        "documentation": "This member refers to Government Sponsored Entities Bond matters."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_FormerRelationshipManagerMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "FormerRelationshipManagerMember",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Former Relationship Manager [Member]",
        "terseLabel": "Customer account matters | Former relationship manager",
        "documentation": "This member refers to criminal judgement of a former Swiss relationship manager."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_ForwardStartingTransactionsReverseRepurchaseAndSecuritiesBorrowingAgreementsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ForwardStartingTransactionsReverseRepurchaseAndSecuritiesBorrowingAgreementsMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Forward Starting Transactions Reverse Repurchase And Securities Borrowing Agreements [Member]",
        "terseLabel": "Forward starting reverse repurchase and securities borrowing agreements",
        "documentation": "This member relates to forward starting transactions, reverse repurchase and securities borrowing agreements."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_FundUnitsNetAssetValueRedemptionRateOffered": {
     "xbrltype": "percentItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "FundUnitsNetAssetValueRedemptionRateOffered",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Fund Units Net Asset Value Redemption Rate Offered",
        "terseLabel": "Rate of net asset value offered to fund investors to redeem their fund units",
        "documentation": "The rate of net asset value offered to fund investors to redeem their fund units."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_FundingAndDebitValuationAdjustments": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "FundingAndDebitValuationAdjustments",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/FVMValuationAdjustmentsReservesOnTheBalanceSheetDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Funding And Debit Valuation Adjustments",
        "terseLabel": "Funding and debit valuation adjustments",
        "documentation": "The amount of valuation adjustments made on financial instruments which reflect the costs and benefits of funding associated with uncollateralized and partially collateralized derivative receivables and payables, and adjustment made to the measurement of derivative liabilities to reflect the own credit risk of the entity."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_FundingObligationRelatedProvision": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "FundingObligationRelatedProvision",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersDetail",
      "http://www.ubsag.com/role/ProvisionsAdditionalInformationDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Funding Obligation Related Provision",
        "terseLabel": "Total IAS 37 provision related to the funding obligation",
        "documentation": "The amount of provision recognized for entity's funding obligation, with no impact on profit or loss to the income statement. related to Litigation, regulatory and similar matters."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_FundingSpreadMeasurementInputMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "FundingSpreadMeasurementInputMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Funding Spread Measurement Input [Member]",
        "terseLabel": "Funding spread",
        "documentation": "This member stands for the funding spread used as a measurement input."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_GBPCurrencyExchangeRateMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "GBPCurrencyExchangeRateMember",
     "presentation": [
      "http://www.ubsag.com/role/BasisOfAccountingCurrencyTranslationRatesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "terseLabel": "1 GBP",
        "documentation": "This member stands for currency translation rate of 1 GBP to the presentation currency.",
        "label": "GBP Currency Exchange Rate [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_GainsLossesArisingInIncomeStatementFromReclassificationOfFinancialAssetsReclassifiedOutOfFairValueThroughOtherComprehensiveIncomeIntoAmortisedCostCategory": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "GainsLossesArisingInIncomeStatementFromReclassificationOfFinancialAssetsReclassifiedOutOfFairValueThroughOtherComprehensiveIncomeIntoAmortisedCostCategory",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/ReclassificationOfFinancialAssetsNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Gains Losses Arising In Income Statement From Reclassification Of Financial Assets Reclassified Out Of Fair Value Through Other Comprehensive Income Into Amortised Cost Category",
        "terseLabel": "Gains (losses) arising in income statement from reclassification of financial assets reclassified out of fair value through other comprehensive income into amortised cost category",
        "documentation": "The gains (losses) arising in income statement from reclassification of financial assets reclassified out of fair value through other comprehensive income into amortised cost category"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_GainsLossesFromAcquisitionsAndDisposalsOfSubsidiaries": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "GainsLossesFromAcquisitionsAndDisposalsOfSubsidiaries",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/OtherIncomeDetail": {
       "parentTag": "ifrs-full_OtherIncomeExpenseFromSubsidiariesJointlyControlledEntitiesAndAssociates",
       "weight": 1.0,
       "order": 3.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Gains Losses From Acquisitions And Disposals Of Subsidiaries",
        "terseLabel": "Net gains / (losses) from acquisitions and disposals of subsidiaries",
        "documentation": "The amount of gains / (losses) from acquisitions and disposals of subsidiaries."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_GainsLossesOnCashFlowHedgesBeforeTax": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "GainsLossesOnCashFlowHedgesBeforeTax",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome": {
       "parentTag": "ifrs-full_OtherComprehensiveIncomeNetOfTaxCashFlowHedges",
       "weight": 1.0,
       "order": 17.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Gains Losses On Cash Flow Hedges Before Tax",
        "terseLabel": "Effective portion of changes in fair value of hedging instruments recognized as Other comprehensive income",
        "verboseLabel": "Effective portion of changes in fair value of derivative instruments designated as cash flow hedges, before tax"
       }
      },
      "en": {
       "role": {
        "documentation": "The gains (losses) recognised in other comprehensive income on cash flow hedges, before tax, before reclassification adjustments. [Refer: Cash flow hedges [member]]"
       }
      }
     },
     "auth_ref": [
      "r33"
     ]
    },
    "ifrs-full_GainsLossesOnExchangeDifferencesOnTranslationBeforeTax": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "GainsLossesOnExchangeDifferencesOnTranslationBeforeTax",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome": {
       "parentTag": "ifrs-full_OtherComprehensiveIncomeNetOfTaxExchangeDifferencesOnTranslation",
       "weight": 1.0,
       "order": 4.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Gains Losses On Exchange Differences On Translation Before Tax",
        "terseLabel": "Foreign currency translation movements related to net assets of foreign operations, before tax"
       }
      },
      "en": {
       "role": {
        "documentation": "The gains (losses) recognised in other comprehensive income on exchange differences on the translation of financial statements of foreign operations, before tax, before reclassification adjustments. [Refer: Other comprehensive income]"
       }
      }
     },
     "auth_ref": [
      "r33"
     ]
    },
    "ifrs-full_GainsLossesOnFinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncomeBeforeTax": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "GainsLossesOnFinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncomeBeforeTax",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome": {
       "parentTag": "ifrs-full_OtherComprehensiveIncomeNetOfTaxFinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncome",
       "weight": 1.0,
       "order": 11.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Gains Losses On Financial Assets Measured At Fair Value Through Other Comprehensive Income Before Tax",
        "terseLabel": "Net unrealized gains / (losses), before tax"
       }
      },
      "en": {
       "role": {
        "documentation": "The gains (losses) recognised in other comprehensive income on financial assets measured at fair value through other comprehensive income applying paragraph 4.1.2A of IFRS 9, before tax, before reclassification adjustments. [Refer: Financial assets measured at fair value through other comprehensive income; Other comprehensive income]"
       }
      }
     },
     "auth_ref": [
      "r33",
      "r139"
     ]
    },
    "ubsag_GainsLossesOnFinancialAssetsReclassifiedOutOfMeasuredAtFairValueThroughOtherComprehensiveIncomeIntoMeasuredAtAmortisedCostNetOfTax": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "GainsLossesOnFinancialAssetsReclassifiedOutOfMeasuredAtFairValueThroughOtherComprehensiveIncomeIntoMeasuredAtAmortisedCostNetOfTax",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncomeParenthetical",
      "http://www.ubsag.com/role/ReclassificationOfFinancialAssetsNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Gains Losses On Financial Assets Reclassified Out Of Measured At Fair Value Through Other Comprehensive Income Into Measured At Amortised Cost Net Of Tax",
        "terseLabel": "Reclassification of financial assets to Other financial assets measured at amortized cost, net of tax",
        "documentation": "The gains (losses) recognised in other comprehensive income related to reclassification of financial assets out of measured at fair value through other comprehensive income category into measured at amortised cost category, net of tax."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_GainsLossesOnFinancialAssetsReclassifiedOutOfMeasuredAtFairValuethroughOtherComprehensiveIncomeIntoMeasuredAtAmortisedCostBeforeTax": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "GainsLossesOnFinancialAssetsReclassifiedOutOfMeasuredAtFairValuethroughOtherComprehensiveIncomeIntoMeasuredAtAmortisedCostBeforeTax",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome": {
       "parentTag": "ifrs-full_OtherComprehensiveIncomeNetOfTaxFinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncome",
       "weight": 1.0,
       "order": 13.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome",
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncomeParenthetical",
      "http://www.ubsag.com/role/ReclassificationOfFinancialAssetsNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Gains Losses On Financial Assets Reclassified Out Of Measured At Fair Value Through Other Comprehensive Income Into Measured At Amortised Cost Before Tax",
        "terseLabel": "Reclassification of financial assets to Other financial assets measured at amortized cost",
        "documentation": "The gains (losses) recognised in other comprehensive income related to reclassification of financial assets out of measured at fair value through other comprehensive income category into measured at amortised cost category, before tax.",
        "verboseLabel": "Reclassification of financial assets to Other financial assets measured at amortized cost, before tax"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_GainsLossesOnHedgesOfNetInvestmentsInForeignOperationsBeforeTax": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "GainsLossesOnHedgesOfNetInvestmentsInForeignOperationsBeforeTax",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome": {
       "parentTag": "ifrs-full_OtherComprehensiveIncomeNetOfTaxExchangeDifferencesOnTranslation",
       "weight": 1.0,
       "order": 5.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Gains Losses On Hedges Of Net Investments In Foreign Operations Before Tax",
        "terseLabel": "Effective portion of changes in fair value of hedging instruments designated as net investment hedges, before tax"
       }
      },
      "en": {
       "role": {
        "documentation": "The gains (losses) recognised in other comprehensive income on hedges of net investments in foreign operations, before tax, before reclassification adjustments. [Refer: Other comprehensive income]"
       }
      }
     },
     "auth_ref": [
      "r33",
      "r63",
      "r190"
     ]
    },
    "ubsag_GainsLossesRecognisedInComprehensiveIncomeFairValueMeasurement": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "GainsLossesRecognisedInComprehensiveIncomeFairValueMeasurement",
     "presentation": [
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Gains Losses Recognised In Comprehensive Income Fair Value Measurement",
        "documentation": "The gains (losses) recognised in comprehensive income."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_GainsLossesRecognisedInIncomeStatementFairValueMeasurement": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "GainsLossesRecognisedInIncomeStatementFairValueMeasurement",
     "presentation": [
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Gains Losses Recognised In Income Statement Fair Value Measurement",
        "documentation": "The gains (losses) recognised in the Income statement under Net interest income and Other net income from financial instruments measured at fair value through profit or loss."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_GainsLossesRecognisedInOtherComprehensiveIncomeFairValueMeasurement": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "GainsLossesRecognisedInOtherComprehensiveIncomeFairValueMeasurement",
     "presentation": [
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Gains Losses Recognised In Other Comprehensive Income Fair Value Measurement",
        "documentation": "The gains (losses) recognised in the Statement of comprehensive income in Gains / (losses) from own credit on financial liabilities designated at fair value, before tax."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_GainsLossesRecognisedInProfitOrLossAttributableToChangeInUnrealisedGainsOrLossesForAssetsHeldAtEndOfPeriodFairValueMeasurement": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "GainsLossesRecognisedInProfitOrLossAttributableToChangeInUnrealisedGainsOrLossesForAssetsHeldAtEndOfPeriodFairValueMeasurement",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Gains Losses Recognised In Profit Or Loss Attributable To Change In Unrealised Gains Or Losses For Assets Held At End Of Period Fair Value Measurement",
        "terseLabel": "Total gains / (losses) included in comprehensive income - of which: related to Level 3 instruments held at the end of the reporting period"
       }
      },
      "en": {
       "role": {
        "documentation": "The gains (losses) recognised in profit or loss for assets measured at fair value that are attributable to the change in unrealised gains or losses relating to those assets held at the end of the reporting period. [Refer: At fair value [member]]"
       }
      }
     },
     "auth_ref": [
      "r104"
     ]
    },
    "ifrs-full_GainsLossesRecognisedInProfitOrLossAttributableToChangeInUnrealisedGainsOrLossesForLiabilitiesHeldAtEndOfPeriodFairValueMeasurement": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "GainsLossesRecognisedInProfitOrLossAttributableToChangeInUnrealisedGainsOrLossesForLiabilitiesHeldAtEndOfPeriodFairValueMeasurement",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Gains Losses Recognised In Profit Or Loss Attributable To Change In Unrealised Gains Or Losses For Liabilities Held At End Of Period Fair Value Measurement",
        "terseLabel": "Total gains / losses included in comprehensive income - of which: related to Level 3 instruments held at the end of the reporting period"
       }
      },
      "en": {
       "role": {
        "documentation": "The gains (losses) recognised in profit or loss for liabilities measured at fair value that are attributable to the change in unrealised gains or losses relating to those liabilities held at the end of the reporting period. [Refer: At fair value [member]]"
       }
      }
     },
     "auth_ref": [
      "r104"
     ]
    },
    "ifrs-full_GainsLossesRecognisedInProfitOrLossFairValueMeasurementAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "GainsLossesRecognisedInProfitOrLossFairValueMeasurementAssets",
     "presentation": [
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Gains Losses Recognised In Profit Or Loss Fair Value Measurement Assets",
        "terseLabel": "Total gains / (losses) included in comprehensive income - Net gains / (losses) included in income"
       }
      },
      "en": {
       "role": {
        "documentation": "The gains (losses) including exchange differences recognised in profit or loss on the fair value measurement of assets. [Refer: At fair value [member]]"
       }
      }
     },
     "auth_ref": [
      "r100"
     ]
    },
    "ifrs-full_GainsLossesRecognisedInProfitOrLossFairValueMeasurementLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "GainsLossesRecognisedInProfitOrLossFairValueMeasurementLiabilities",
     "presentation": [
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Gains Losses Recognised In Profit Or Loss Fair Value Measurement Liabilities",
        "terseLabel": "Total gains / losses included in comprehensive income - Net gains / losses included in income"
       }
      },
      "en": {
       "role": {
        "documentation": "The gains (losses) including exchange differences recognised in profit or loss on the fair value measurement of liabilities. [Refer: At fair value [member]]"
       }
      }
     },
     "auth_ref": [
      "r100"
     ]
    },
    "ifrs-full_GainsOnLitigationSettlements": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "GainsOnLitigationSettlements",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "terseLabel": "Recoveries from third parties",
        "label": "Gains On Litigation Settlements"
       }
      },
      "en": {
       "role": {
        "documentation": "The gain on settlements of litigation."
       }
      }
     },
     "auth_ref": [
      "r35"
     ]
    },
    "ifrs-full_GeneralAndAdministrativeExpense": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "GeneralAndAdministrativeExpense",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement": {
       "parentTag": "ifrs-full_ExpenseByNature",
       "weight": 1.0,
       "order": 14.0
      },
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesDetail": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement",
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "totalLabel": "Total general and administrative expenses",
        "terseLabel": "General and administrative expenses",
        "label": "General And Administrative Expense"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of expense relating to general and administrative activities of the entity."
       }
      }
     },
     "auth_ref": [
      "r247"
     ]
    },
    "ubsag_GeneralAndAdministrativeExpensesLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "GeneralAndAdministrativeExpensesLineItems",
     "presentation": [
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpenses",
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesDetail",
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "General And Administrative Expenses [Line Items]",
        "terseLabel": "General And Administrative Expenses",
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with domain members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_GeneralAndAdministrativeProvisionsAndLosses": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "GeneralAndAdministrativeProvisionsAndLosses",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesDetail": {
       "parentTag": "ifrs-full_GeneralAndAdministrativeExpense",
       "weight": 1.0,
       "order": 9.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "General And Administrative Provisions And Losses",
        "terseLabel": "Litigation, regulatory and similar matters",
        "documentation": "The amount of net expenses for provisions for litigation, regulatory and similar matters."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_GeographicalAreasAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "GeographicalAreasAxis",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementComparisonOfShockFactorsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Geographical Areas [Axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r186",
      "r202",
      "r219",
      "r222"
     ]
    },
    "ifrs-full_GeographicalAreasMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "GeographicalAreasMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementComparisonOfShockFactorsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Geographical Areas [Member]",
        "terseLabel": "Total"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for aggregated geographical areas. It also represents the standard value for the 'Geographical areas' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r186",
      "r202",
      "r219",
      "r222"
     ]
    },
    "ifrs-full_GoodsOrServicesTransferredAtPointInTimeMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "GoodsOrServicesTransferredAtPointInTimeMember",
     "presentation": [
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Goods Or Services Transferred At Point In Time [Member]",
        "terseLabel": "of which: transaction-based"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for goods or services transferred to customers at a point in time. [Refer: Performance obligations satisfied at point in time [member]]"
       }
      }
     },
     "auth_ref": [
      "r220"
     ]
    },
    "ubsag_GoodsOrServicesTransferredOnPerformancebasedBasisMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "GoodsOrServicesTransferredOnPerformancebasedBasisMember",
     "presentation": [
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "This member stands for goods or services transferred to customers on a performance-based basis.",
        "terseLabel": "of which: performance-based",
        "label": "Goods Or Services Transferred On Performance-based Basis [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_GoodsOrServicesTransferredOnRecurringBasisMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "GoodsOrServicesTransferredOnRecurringBasisMember",
     "presentation": [
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Goods Or Services Transferred On Recurring Basis [Member]",
        "terseLabel": "of which: recurring",
        "documentation": "This member stands for goods or services transferred to customers on a recurring basis."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_GovernmentBillsBondsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "GovernmentBillsBondsMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail",
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Government Bills Bonds [Member]",
        "terseLabel": "Government bills / bonds",
        "documentation": "This member relates to government bills and/or bonds."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_GrossCarryingAmountMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "GrossCarryingAmountMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Gross Carrying Amount [Member]",
        "terseLabel": "Gross carrying amount",
        "verboseLabel": "Gross impaired financial instruments"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for the amount at which an asset is recognised before deducting any accumulated depreciation (amortisation) and accumulated impairment losses thereon. [Refer: Depreciation and amortisation expense; Impairment loss]"
       }
      }
     },
     "auth_ref": [
      "r42",
      "r61",
      "r67",
      "r70",
      "r129",
      "r152",
      "r158",
      "r228"
     ]
    },
    "ubsag_GrossDomesticProductMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "GrossDomesticProductMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementComparisonOfShockFactorsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Gross Domestic Product [Member]",
        "verboseLabel": "Real GDP growth (annual percentage change)",
        "documentation": "This member stands for changes of gross domestic product (GDP)."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_HighestRankingManagersResponsibilitiesToBeDefined": {
     "xbrltype": "integerItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "HighestRankingManagersResponsibilitiesToBeDefined",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Highest Ranking Managers Responsibilities To Be Defined",
        "terseLabel": "Highest-ranking managers to have their responsibilities defined",
        "documentation": "The amount of highest-ranking managers to have their responsibilities defined."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_HistoricalVolatilityForInflationMeasurementInputMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "HistoricalVolatilityForInflationMeasurementInputMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Historical Volatility For Inflation Measurement Input [Member]",
        "terseLabel": "Volatility of inflation",
        "documentation": "This member stands for the historical volatility for inflation used as a measurement input."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_HistoricalVolatilityForInterestRatesMeasurementInputMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "HistoricalVolatilityForInterestRatesMeasurementInputMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Historical Volatility For Interest Rates Measurement Input [Member]",
        "terseLabel": "Volatility of interest rates",
        "documentation": "This member stands for the historical volatility for interest rates used as a measurement input."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_HistoricalVolatilityForSharesMeasurementInputMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "HistoricalVolatilityForSharesMeasurementInputMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Historical Volatility For Shares Measurement Input [Member]",
        "terseLabel": "Volatility of equity stocks, equity and other indices"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for the historical volatility for shares used as a measurement input."
       }
      }
     },
     "auth_ref": [
      "r214"
     ]
    },
    "ubsag_HomeEquityAssetTrust20071Member": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "HomeEquityAssetTrust20071Member",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Home Equity Asset Trust 2007 1 [Member]",
        "terseLabel": "Mortgage-related matters | Action brought by Home Equity Asset Trust 2007-1",
        "documentation": "This member refers to action brought by Home Equity Asset Trust 2007-1."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_HomeEquityAssetTrust20072Member": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "HomeEquityAssetTrust20072Member",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Home Equity Asset Trust 2007 2 [Member]",
        "terseLabel": "Mortgage-related matters | Action brought by Home Equity Asset Trust 2007-2",
        "documentation": "This member refers to action brought by Home Equity Asset Trust 2007-2."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_HomeEquityAssetTrustSeries20068Member": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "HomeEquityAssetTrustSeries20068Member",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Home Equity Asset Trust Series 2006 8 [Member]",
        "terseLabel": "Mortgage-related matters | Action brought by Home Equity Asset Trust, Series 2006-8",
        "documentation": "This member refers to action brought by Home Equity Asset Trust, Series 2006-8."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_IRToIRCorrelationMeasurementInputMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "IRToIRCorrelationMeasurementInputMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "IR To IR Correlation Measurement Input [Member]",
        "terseLabel": "IR-to-IR correlation",
        "documentation": "This member stands for IR-to-IR correlation used as a measurement input."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ImpairmentLossImpairmentGainAndReversalOfImpairmentLossDeterminedInAccordanceWithIFRS9": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ImpairmentLossImpairmentGainAndReversalOfImpairmentLossDeterminedInAccordanceWithIFRS9",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement": {
       "parentTag": "ifrs-full_ProfitLossBeforeTax",
       "weight": -1.0,
       "order": 12.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpenseReleaseNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpensereleaseDetail",
      "http://www.ubsag.com/role/SegmentReportingDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Impairment Loss Impairment Gain And Reversal Of Impairment Loss Determined In Accordance With IFRS9",
        "negatedLabel": "Credit loss (expense) / release",
        "terseLabel": "Credit loss expense / (release)",
        "negatedTerseLabel": "Recognition of ECL (IFRS 9)",
        "positiveVerboseLabel": "Expected credit loss adjusted with scenario weights"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of impairment loss, impairment gain or reversal of impairment loss that is recognised in profit or loss in accordance with paragraph 5.5.8 of IFRS 9 and that arises from applying the impairment requirements in Section 5.5 of IFRS 9."
       }
      }
     },
     "auth_ref": [
      "r28"
     ]
    },
    "ifrs-full_ImpairmentOfFinancialAssetsAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ImpairmentOfFinancialAssetsAxis",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementChangesToECLModelsScenariosScenarioWeightsAndPostmodelAdjustmentsNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpenseReleaseNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Impairment Of Financial Assets [Axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r193"
     ]
    },
    "ifrs-full_IncomeStatementAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "IncomeStatementAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Income Statement [Abstract]",
        "terseLabel": "Income statement"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_IncomeStatementLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "IncomeStatementLineItems",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Income Statement [Line Items]",
        "terseLabel": "Income statement",
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with domain members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_IncomeTaxEffectsAllocatedDirectlyToEquityOther": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "IncomeTaxEffectsAllocatedDirectlyToEquityOther",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Tax (expense) / benefit",
        "label": "Income Tax Effects Allocated Directly To Equity Other",
        "documentation": "The tax effect of items occurring during the period that have been charged or credited directly to components of shareholders' equity and are not otherwise defined."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_IncomeTaxExpenseContinuingOperations": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "IncomeTaxExpenseContinuingOperations",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement": {
       "parentTag": "ifrs-full_ProfitLoss",
       "weight": -1.0,
       "order": 18.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement",
      "http://www.ubsag.com/role/SegmentReportingDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Income Tax Expense Continuing Operations",
        "terseLabel": "Tax expense / (benefit)",
        "totalLabel": "Income tax expense / (benefit)",
        "verboseLabel": "Tax expense / (benefit)",
        "negatedLabel": "Tax expense / (benefit)",
        "positiveTerseLabel": "Net tax expense"
       }
      },
      "en": {
       "role": {
        "documentation": "The aggregate amount included in the determination of profit (loss) for the period in respect of current tax and deferred tax. [Refer: Current tax expense (income); Deferred tax expense (income)]"
       }
      }
     },
     "auth_ref": [
      "r30",
      "r37",
      "r39",
      "r40",
      "r50",
      "r95",
      "r175"
     ]
    },
    "ifrs-full_IncomeTaxRelatingToCashFlowHedgesOfOtherComprehensiveIncome": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "IncomeTaxRelatingToCashFlowHedgesOfOtherComprehensiveIncome",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome": {
       "parentTag": "ifrs-full_OtherComprehensiveIncomeNetOfTaxCashFlowHedges",
       "weight": -1.0,
       "order": 19.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Income Tax Relating To Cash Flow Hedges Of Other Comprehensive Income",
        "negatedLabel": "Income tax relating to cash flow hedges",
        "terseLabel": "Income tax relating to cash flow hedges"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of income tax relating to amounts recognised in other comprehensive income in relation to cash flow hedges. [Refer: Cash flow hedges [member]; Other comprehensive income]"
       }
      }
     },
     "auth_ref": [
      "r31",
      "r38"
     ]
    },
    "ifrs-full_IncomeTaxRelatingToChangeInValueOfForeignCurrencyBasisSpreadsOfOtherComprehensiveIncome": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "IncomeTaxRelatingToChangeInValueOfForeignCurrencyBasisSpreadsOfOtherComprehensiveIncome",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome": {
       "parentTag": "ifrs-full_OtherComprehensiveIncomeNetOfTaxChangeInValueOfForeignCurrencyBasisSpreads",
       "weight": -1.0,
       "order": 23.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Income Tax Relating To Change In Value Of Foreign Currency Basis Spreads Of Other Comprehensive Income",
        "negatedLabel": "Income tax relating to cost of hedging"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of income tax relating to amounts recognised in other comprehensive income in relation to change in value of foreign currency basis spreads. [Refer: Reserve of change in value of foreign currency basis spreads; Other comprehensive income]"
       }
      }
     },
     "auth_ref": [
      "r31",
      "r38"
     ]
    },
    "ifrs-full_IncomeTaxRelatingToChangesInFairValueOfFinancialLiabilityAttributableToChangeInCreditRiskOfLiabilityOfOtherComprehensiveIncome": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "IncomeTaxRelatingToChangesInFairValueOfFinancialLiabilityAttributableToChangeInCreditRiskOfLiabilityOfOtherComprehensiveIncome",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome": {
       "parentTag": "ifrs-full_OtherComprehensiveIncomeNetOfTaxChangeInFairValueOfFinancialLiabilityAttributableToChangeInCreditRiskOfLiability",
       "weight": -1.0,
       "order": 31.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Income Tax Relating To Changes In Fair Value Of Financial Liability Attributable To Change In Credit Risk Of Liability Of Other Comprehensive Income",
        "negatedLabel": "Income tax relating to own credit on financial liabilities designated at fair value"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of income tax relating to amounts recognised in other comprehensive income in relation to changes in the fair value of financial liabilities attributable to a change in the credit risk of those liabilities. [Refer: Credit risk [member]; Other comprehensive income]"
       }
      }
     },
     "auth_ref": [
      "r31",
      "r38"
     ]
    },
    "ifrs-full_IncomeTaxRelatingToExchangeDifferencesOnTranslationOfOtherComprehensiveIncome": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "IncomeTaxRelatingToExchangeDifferencesOnTranslationOfOtherComprehensiveIncome",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome": {
       "parentTag": "ifrs-full_OtherComprehensiveIncomeNetOfTaxExchangeDifferencesOnTranslation",
       "weight": -1.0,
       "order": 8.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Income Tax Relating To Exchange Differences On Translation Of Other Comprehensive Income",
        "negatedLabel": "Income tax relating to foreign currency translations, including the effect of net investment hedges"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of income tax relating to amounts recognised in other comprehensive income in relation to exchange differences on the translation of financial statements of foreign operations. [Refer: Other comprehensive income; Reserve of exchange differences on translation]"
       }
      }
     },
     "auth_ref": [
      "r31",
      "r38"
     ]
    },
    "ifrs-full_IncomeTaxRelatingToFinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncome": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "IncomeTaxRelatingToFinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncome",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome": {
       "parentTag": "ifrs-full_OtherComprehensiveIncomeNetOfTaxFinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncome",
       "weight": -1.0,
       "order": 14.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Income Tax Relating To Financial Assets Measured At Fair Value Through Other Comprehensive Income",
        "negatedLabel": "Income tax relating to net unrealized gains / (losses)"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of income tax relating to amounts recognised in other comprehensive income in relation to financial assets measured at fair value through other comprehensive income applying paragraph 4.1.2A of IFRS 9. [Refer: Financial assets measured at fair value through other comprehensive income; Other comprehensive income]"
       }
      }
     },
     "auth_ref": [
      "r31",
      "r38"
     ]
    },
    "ifrs-full_IncomeTaxRelatingToRemeasurementsOfDefinedBenefitPlansOfOtherComprehensiveIncome": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "IncomeTaxRelatingToRemeasurementsOfDefinedBenefitPlansOfOtherComprehensiveIncome",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome": {
       "parentTag": "ifrs-full_OtherComprehensiveIncomeNetOfTaxGainsLossesOnRemeasurementsOfDefinedBenefitPlans",
       "weight": -1.0,
       "order": 27.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Income Tax Relating To Remeasurements Of Defined Benefit Plans Of Other Comprehensive Income",
        "negatedLabel": "Income tax relating to defined benefit plans",
        "negatedTerseLabel": "Tax (expense) / benefit relating to defined benefit plans recognized in other comprehensive income"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of income tax relating to amounts recognised in other comprehensive income in relation to remeasurements of defined benefit plans. [Refer: Other comprehensive income; Reserve of remeasurements of defined benefit plans; Defined benefit plans [member]]"
       }
      }
     },
     "auth_ref": [
      "r31",
      "r38"
     ]
    },
    "ifrs-full_IncomeTaxesPaidRefund": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "IncomeTaxesPaidRefund",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperatingActivities",
       "weight": -1.0,
       "order": 23.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Income Taxes Paid Refund",
        "negatedLabel": "Income taxes paid, net of refunds"
       }
      },
      "en": {
       "role": {
        "documentation": "The cash flows from income taxes paid or refunded."
       }
      }
     },
     "auth_ref": [
      "r78"
     ]
    },
    "ubsag_IncreaseDecreaseExpectedCreditLossRate": {
     "xbrltype": "percentItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "IncreaseDecreaseExpectedCreditLossRate",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementECLrelevantBalanceSheetAndOffbalanceSheetPositionsIncludingECLAllowancesAndProvisionsNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Increase Decrease Expected Credit Loss Rate",
        "terseLabel": "Increase decrease in ECL coverage",
        "documentation": "Increase or decrease in the rate of expected credit losses, calculated as percentage of the gross carrying amount. Expected credit losses are the weighted average of credit losses with the respective risks of a default occurring as the weights."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_IncreaseDecreaseInAssetsRestatementResult": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "IncreaseDecreaseInAssetsRestatementResult",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/SegmentReportingNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Increase Decrease In Assets Restatement Result",
        "documentation": "The amount of increase / (decrease) in present economic resource controlled by the entity as a result of past events. Economic resource is a right that has the potential to produce economic benefits, due to restatement.",
        "terseLabel": "Increase / (decrease) in total assets due to restatement"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_IncreaseDecreaseInCashAndCashEquivalentsBeforeEffectOfExchangeRateChanges": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "IncreaseDecreaseInCashAndCashEquivalentsBeforeEffectOfExchangeRateChanges",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Increase Decrease In Cash And Cash Equivalents Before Effect Of Exchange Rate Changes",
        "totalLabel": "Net cash flow from / (used in) operating, investing and financing activities",
        "terseLabel": "Net cash flow from / (used in) operating, investing and financing activities"
       }
      },
      "en": {
       "role": {
        "documentation": "The increase (decrease) in cash and cash equivalents before the effect of exchange rate changes on cash and cash equivalents held in foreign currencies. [Refer: Cash and cash equivalents; Effect of exchange rate changes on cash and cash equivalents]"
       }
      }
     },
     "auth_ref": [
      "r80"
     ]
    },
    "ubsag_IncreaseDecreaseInJointAndSeveralLiability": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "IncreaseDecreaseInJointAndSeveralLiability",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/SupplementalGuarantorInformationNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Increase Decrease In Joint And Several Liability",
        "terseLabel": "Increase decrease in joint and several liability",
        "documentation": "The joint liability for contractual obligations of UBS AG decreased by."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_IncreaseDecreaseInOtherOperatingAssetsAndLiabilitiesNetAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "IncreaseDecreaseInOtherOperatingAssetsAndLiabilitiesNetAbstract",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Increase Decrease In Other Operating Assets And Liabilities Net Abstract",
        "terseLabel": "Net change in operating assets and liabilities:"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_IncreaseDecreaseInProfitLossBeforeTaxRestatementResult": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "IncreaseDecreaseInProfitLossBeforeTaxRestatementResult",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/SegmentReportingNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Increase Decrease In Profit Loss Before Tax Restatement Result",
        "terseLabel": "Increase / (decrease) in operating profit / (loss) before tax due to restatement",
        "documentation": "The amount of increase / (decrease) in profit (loss) before tax expense or income, due to restatement."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_IncreaseDecreaseThroughAmountsRecognisedInProfitOrLossAggregateDifferenceBetweenFairValueAtInitialRecognitionAndAmountDeterminedUsingValuationTechniqueYetToBeRecognised": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "IncreaseDecreaseThroughAmountsRecognisedInProfitOrLossAggregateDifferenceBetweenFairValueAtInitialRecognitionAndAmountDeterminedUsingValuationTechniqueYetToBeRecognised",
     "presentation": [
      "http://www.ubsag.com/role/FVMValuationAdjustmentsDeferredDay1PLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Increase Decrease Through Amounts Recognised In Profit Or Loss Aggregate Difference Between Fair Value At Initial Recognition And Amount Determined Using Valuation Technique Yet To Be Recognised",
        "terseLabel": "(Profit) / loss recognized in the income statement"
       }
      },
      "en": {
       "role": {
        "documentation": "The increase (decrease) in the aggregate difference between the fair value at initial recognition and the transaction price of financial instruments yet to be recognised in profit or loss resulting from amounts recognised in profit or loss. [Refer: Aggregate difference between fair value at initial recognition and transaction price yet to be recognised in profit or loss; Financial instruments, class [member]]"
       }
      }
     },
     "auth_ref": [
      "r226",
      "r234"
     ]
    },
    "ubsag_IncreaseDecreaseThroughBusinessCombinationAggregateDifferenceBetweenFairValueAtInitialRecognitionAndAmountDeterminedUsingValuationTechniqueYetToBeRecognised": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "IncreaseDecreaseThroughBusinessCombinationAggregateDifferenceBetweenFairValueAtInitialRecognitionAndAmountDeterminedUsingValuationTechniqueYetToBeRecognised",
     "presentation": [
      "http://www.ubsag.com/role/FVMValuationAdjustmentsDeferredDay1PLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Increase Decrease Through Business Combination Aggregate Difference Between Fair Value At Initial Recognition And Amount Determined Using Valuation Technique Yet To Be Recognised",
        "terseLabel": "Effect from a business combination",
        "documentation": "The increase (decrease) in the aggregate difference between the fair value at initial recognition and the transaction price of financial instruments yet to be recognised in profit or loss resulting from a business combination."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_IncreaseDecreaseThroughChangesInRetainedEarningsOfAssociatesAndJointVentures": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "IncreaseDecreaseThroughChangesInRetainedEarningsOfAssociatesAndJointVentures",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Increase Decrease Through Changes In Retained Earnings Of Associates And Joint Ventures",
        "terseLabel": "Share of changes in retained earnings of associates and joint ventures",
        "documentation": "The increase (decrease) in equity resulting from changes in retained earnings of associates and joint ventures."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_IncreaseDecreaseThroughNetExchangeDifferencesAggregateDifferenceBetweenFairValueAtInitialRecognitionAndAmountDeterminedUsingValuationtechniqueYetToBeRecognised": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "IncreaseDecreaseThroughNetExchangeDifferencesAggregateDifferenceBetweenFairValueAtInitialRecognitionAndAmountDeterminedUsingValuationtechniqueYetToBeRecognised",
     "presentation": [
      "http://www.ubsag.com/role/FVMValuationAdjustmentsDeferredDay1PLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Increase Decrease Through Net Exchange Differences Aggregate Difference Between Fair Value At Initial Recognition And Amount Determined Using ValuationTechnique Yet To Be Recognised",
        "terseLabel": "Foreign currency translation",
        "documentation": "The increase (decrease) in the aggregate difference between the fair value at initial recognition and the transaction price of financial instruments yet to be recognised in profit or loss resulting from foreign currency translation."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_IncreaseDecreaseThroughNetExchangeDifferencesAndTimeValueOfMoneyAdjustmentOtherProvisions": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "IncreaseDecreaseThroughNetExchangeDifferencesAndTimeValueOfMoneyAdjustmentOtherProvisions",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersDetail",
      "http://www.ubsag.com/role/ProvisionsAdditionalInformationDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Increase Decrease Through Net Exchange Differences And Time Value Of Money Adjustment Other Provisions",
        "terseLabel": "Foreign currency translation and other movements",
        "documentation": "The increase (decrease) in other provisions resulting from (i) foreign currency exchange rate changes on provisions measured in a currency different from the entity's presentation currency; (ii) other movements (for example, capitalized reinstatement cost); and (iii) adjustments arising from the passage of time.",
        "verboseLabel": "Foreign currency translation / unwind of discount"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_IncreaseDecreaseThroughNetExchangeDifferencesRecognizedDirectlyInRetainedEarnings": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "IncreaseDecreaseThroughNetExchangeDifferencesRecognizedDirectlyInRetainedEarnings",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Increase Decrease Through Net Exchange Differences Recognized Directly In Retained Earnings",
        "terseLabel": "Translation effects recognized directly in retained earnings",
        "documentation": "The increase (decrease) in equity resulting from translation effects recognized directly in retained earnings."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_IncreaseDecreaseThroughNewTransactionsAggregateDifferenceBetweenFairValueAtInitialRecognitionAndAmountDeterminedUsingValuationTechniqueYetToBeRecognised": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "IncreaseDecreaseThroughNewTransactionsAggregateDifferenceBetweenFairValueAtInitialRecognitionAndAmountDeterminedUsingValuationTechniqueYetToBeRecognised",
     "presentation": [
      "http://www.ubsag.com/role/FVMValuationAdjustmentsDeferredDay1PLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Increase Decrease Through New Transactions Aggregate Difference Between Fair Value At Initial Recognition And Amount Determined Using Valuation Technique Yet To Be Recognised",
        "terseLabel": "Profit / (loss) deferred on new transactions"
       }
      },
      "en": {
       "role": {
        "documentation": "The increase (decrease) in the aggregate difference between the fair value at initial recognition and the transaction price of financial instruments yet to be recognised in profit or loss resulting from new transactions. [Refer: Aggregate difference between fair value at initial recognition and transaction price yet to be recognised in profit or loss; Financial instruments, class [member]]"
       }
      }
     },
     "auth_ref": [
      "r226",
      "r234"
     ]
    },
    "ifrs-full_IncreaseDecreaseThroughSharebasedPaymentTransactions": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "IncreaseDecreaseThroughSharebasedPaymentTransactions",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Increase Decrease Through Sharebased Payment Transactions",
        "terseLabel": "Share-based compensation expensed in the income statement"
       }
      },
      "en": {
       "role": {
        "documentation": "The increase (decrease) in equity resulting from share-based payment transactions. [Refer: Equity]"
       }
      }
     },
     "auth_ref": [
      "r4"
     ]
    },
    "ifrs-full_IncreaseDecreaseThroughTransfersAndOtherChangesEquity": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "IncreaseDecreaseThroughTransfersAndOtherChangesEquity",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Increase Decrease Through Transfers And Other Changes Equity",
        "terseLabel": "New consolidations / (deconsolidations) and other increases / (decreases)"
       }
      },
      "en": {
       "role": {
        "documentation": "The increase (decrease) in equity resulting from changes that the entity does not separately disclose in the same statement or note. [Refer: Equity]"
       }
      }
     },
     "auth_ref": [
      "r5"
     ]
    },
    "ifrs-full_IncreaseDecreaseThroughTreasuryShareTransactions": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "IncreaseDecreaseThroughTreasuryShareTransactions",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Increase Decrease Through Treasury Share Transactions",
        "terseLabel": "Delivery of treasury shares under share-based compensation plans"
       }
      },
      "en": {
       "role": {
        "documentation": "The increase (decrease) in equity resulting from treasury share transactions. [Refer: Equity; Treasury shares]"
       }
      }
     },
     "auth_ref": [
      "r5"
     ]
    },
    "ubsag_IncreaseInFairValueMeasurementDueToChangeInMultipleUnobservableInputsToReflectReasonablyPossibleAlternativeAssumptionsAssetsAndLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "IncreaseInFairValueMeasurementDueToChangeInMultipleUnobservableInputsToReflectReasonablyPossibleAlternativeAssumptionsAssetsAndLiabilities",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsSensitivityToChangesInUnobservableInputAssumptionsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Increase In Fair Value Measurement Due To Change In Multiple Unobservable Inputs To Reflect Reasonably Possible Alternative Assumptions Assets And Liabilities",
        "terseLabel": "Favorable changes",
        "documentation": "The amount of increase in the fair value measurement of assets due to a change in multiple unobservable inputs to reflect reasonably possible alternative assumptions."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_IncreaseInFundingObligationRelatedProvision": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "IncreaseInFundingObligationRelatedProvision",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersDetail",
      "http://www.ubsag.com/role/ProvisionsAdditionalInformationDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Increase In Funding Obligation Related Provision",
        "terseLabel": "Increase in IAS 37 provision related to the funding obligation",
        "documentation": "The amount of an increase in a provision for entity's funding obligation, with a respective impact on the income statement, related to Litigation, regulatory and similar matters."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_IncreaseOfConsumerReliefPerAnnum": {
     "xbrltype": "percentItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "IncreaseOfConsumerReliefPerAnnum",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Increase Of Consumer Relief Per Annum",
        "terseLabel": "Increase of customer relief per annum",
        "documentation": "The increase of customer relief per annum."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_InflowsOfCashFromSecuritiesFinancingTransactionsMeasuredAtAmortizedCost": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "InflowsOfCashFromSecuritiesFinancingTransactionsMeasuredAtAmortizedCost",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInFinancingActivities",
       "weight": 1.0,
       "order": 41.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Inflows Of Cash From Securities Financing Transactions Measured At Amortized Cost",
        "terseLabel": "Inflows from securities financing transactions measured at amortized cost",
        "documentation": "Reflects cash inflows from securities financing transactions measured at amortized cost that use entity's debt instruments as the underlying."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_InformationTechnologyExpenses": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "InformationTechnologyExpenses",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesDetail": {
       "parentTag": "ifrs-full_GeneralAndAdministrativeExpense",
       "weight": 1.0,
       "order": 3.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Information Technology Expenses",
        "terseLabel": "Technology costs",
        "documentation": "The amount of expense incurred in the period for rent and maintenance of IT and other equipment."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_IntangibleAssetsAndGoodwill": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "IntangibleAssetsAndGoodwill",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_Assets",
       "weight": 1.0,
       "order": 19.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Intangible Assets And Goodwill",
        "terseLabel": "Goodwill and intangible assets",
        "periodStartLabel": "Balance at the beginning of the year",
        "periodEndLabel": "Balance at the end of the year"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of intangible assets and goodwill held by the entity. [Refer: Goodwill; Intangible assets other than goodwill]"
       }
      }
     },
     "auth_ref": [
      "r249"
     ]
    },
    "ubsag_IntangibleAssetsAndGoodwillTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "IntangibleAssetsAndGoodwillTransferredAsOfTheMergerDate",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Intangible Assets And Goodwill Transferred As Of The Merger Date",
        "terseLabel": "Goodwill and intangible assets",
        "documentation": "The amount of intangible assets and goodwill held by the entity."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_InterestExpenseForFinancialLiabilitiesNotAtFairValueThroughProfitOrLoss": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "InterestExpenseForFinancialLiabilitiesNotAtFairValueThroughProfitOrLoss",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement": {
       "parentTag": "ifrs-full_InterestRevenueExpense",
       "weight": -1.0,
       "order": 3.0
      },
      "http://www.ubsag.com/role/NetInterestIncomeDetail": {
       "parentTag": "ubsag_NetInterestIncomeFromFinancialInstrumentsMeasuredAtAmortizedCostAndFairValueThroughOtherComprehensiveIncome",
       "weight": -1.0,
       "order": 12.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement",
      "http://www.ubsag.com/role/NetInterestIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest Expense For Financial Liabilities Not At Fair Value Through Profit Or Loss",
        "negatedLabel": "Interest expense from financial instruments measured at amortized cost",
        "totalLabel": "Total interest expense from financial instruments measured at amortized cost"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of interest expense for financial liabilities that are not at fair value through profit or loss. [Refer: At fair value [member]; Interest expense; Financial liabilities]"
       }
      }
     },
     "auth_ref": [
      "r140"
     ]
    },
    "ifrs-full_InterestExpenseOnDebtInstrumentsIssued": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "InterestExpenseOnDebtInstrumentsIssued",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/NetInterestIncomeDetail": {
       "parentTag": "ifrs-full_InterestExpenseForFinancialLiabilitiesNotAtFairValueThroughProfitOrLoss",
       "weight": 1.0,
       "order": 10.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/NetInterestIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest Expense On Debt Instruments Issued",
        "terseLabel": "Interest expense on debt issued"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of interest expense on debt instruments issued. [Refer: Interest expense; Debt instruments issued]"
       }
      }
     },
     "auth_ref": [
      "r247"
     ]
    },
    "ifrs-full_InterestExpenseOnLeaseLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "InterestExpenseOnLeaseLiabilities",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/NetInterestIncomeDetail": {
       "parentTag": "ifrs-full_InterestExpenseForFinancialLiabilitiesNotAtFairValueThroughProfitOrLoss",
       "weight": 1.0,
       "order": 11.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/NetInterestIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest Expense On Lease Liabilities",
        "terseLabel": "Interest expense on lease liabilities"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of interest expense on lease liabilities. [Refer: Lease liabilities]"
       }
      }
     },
     "auth_ref": [
      "r115"
     ]
    },
    "ubsag_InterestExpenseOnLoansAndDeposits": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "InterestExpenseOnLoansAndDeposits",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/NetInterestIncomeDetail": {
       "parentTag": "ifrs-full_InterestExpenseForFinancialLiabilitiesNotAtFairValueThroughProfitOrLoss",
       "weight": 1.0,
       "order": 8.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/NetInterestIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest Expense On Loans And Deposits",
        "terseLabel": "Interest expense on loans and deposits",
        "documentation": "The amount of interest expense on amounts due to banks, cash collateral payables on derivative instruments, customer deposits, and funding from UBS Group AG, as well as negative interest on cash and balances at central banks, loans and advances to banks, and cash collateral receivables on derivative instruments."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_InterestExpenseOnSecuritiesFinancingTransactions": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "InterestExpenseOnSecuritiesFinancingTransactions",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/NetInterestIncomeDetail": {
       "parentTag": "ifrs-full_InterestExpenseForFinancialLiabilitiesNotAtFairValueThroughProfitOrLoss",
       "weight": 1.0,
       "order": 9.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/NetInterestIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest Expense On Securities Financing Transactions",
        "terseLabel": "Interest expense on securities financing transactions measured at amortized cost",
        "documentation": "The amount of interest expense on securities lent and repurchase agreements and negative interest, including fees, on securities borrowed and reverse repurchase agreements."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_InterestIncomeForFinancialAssetsNotAtFairValueThroughProfitOrLoss": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "InterestIncomeForFinancialAssetsNotAtFairValueThroughProfitOrLoss",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement": {
       "parentTag": "ifrs-full_InterestRevenueExpense",
       "weight": 1.0,
       "order": 2.0
      },
      "http://www.ubsag.com/role/NetInterestIncomeDetail": {
       "parentTag": "ubsag_NetInterestIncomeFromFinancialInstrumentsMeasuredAtAmortizedCostAndFairValueThroughOtherComprehensiveIncome",
       "weight": 1.0,
       "order": 7.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement",
      "http://www.ubsag.com/role/NetInterestIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest Income For Financial Assets Not At Fair Value Through Profit Or Loss",
        "terseLabel": "Interest income from financial instruments measured at amortized cost and fair value through other comprehensive income",
        "totalLabel": "Total interest income from financial instruments measured at amortized cost and fair value through other comprehensive income"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of income arising from interest for financial assets that are not at fair value through profit or loss. [Refer: Interest income]"
       }
      }
     },
     "auth_ref": [
      "r192"
     ]
    },
    "ubsag_InterestIncomeForOtherFinancialAssetsMeasuredAtAmortisedCost": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "InterestIncomeForOtherFinancialAssetsMeasuredAtAmortisedCost",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/NetInterestIncomeDetail": {
       "parentTag": "ifrs-full_InterestIncomeForFinancialAssetsNotAtFairValueThroughProfitOrLoss",
       "weight": 1.0,
       "order": 4.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/NetInterestIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The amount of revenue arising from interest for financial assets that are measured at amortised cost.",
        "terseLabel": "Interest income from other financial instruments measured at amortized cost",
        "label": "Interest Income For Other Financial Assets Measured At Amortised Cost"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_InterestIncomeFromDebtInstrumentsMeasuredAtFairValueThroughOtherComprehensiveIncome": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "InterestIncomeFromDebtInstrumentsMeasuredAtFairValueThroughOtherComprehensiveIncome",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/NetInterestIncomeDetail": {
       "parentTag": "ifrs-full_InterestIncomeForFinancialAssetsNotAtFairValueThroughProfitOrLoss",
       "weight": 1.0,
       "order": 5.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/NetInterestIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest Income From Debt Instruments Measured At Fair Value Through Other Comprehensive Income",
        "terseLabel": "Interest income from debt instruments measured at fair value through other comprehensive income",
        "definitionGuidance": "The amount of interest income from debt instruments measured at fair value through other comprehensive income."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_InterestIncomeFromHedgingInstrumentsCashFlowHedges": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "InterestIncomeFromHedgingInstrumentsCashFlowHedges",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/NetInterestIncomeDetail": {
       "parentTag": "ifrs-full_InterestIncomeForFinancialAssetsNotAtFairValueThroughProfitOrLoss",
       "weight": 1.0,
       "order": 6.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/NetInterestIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest Income From Hedging Instruments Cash Flow Hedges",
        "documentation": "The amount of interest income from derivative instruments designated as hedging instruments for cash flow hedges.",
        "terseLabel": "Interest income from derivative instruments designated as cash flow hedges"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_InterestIncomeFromLoansAndDeposits": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "InterestIncomeFromLoansAndDeposits",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/NetInterestIncomeDetail": {
       "parentTag": "ifrs-full_InterestIncomeForFinancialAssetsNotAtFairValueThroughProfitOrLoss",
       "weight": 1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/NetInterestIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest Income From Loans And Deposits",
        "terseLabel": "Interest income from loans and deposits",
        "documentation": "The amount of interest income from balances with central banks, amounts due from banks and loans, and negative interest on amounts due to banks and customers."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_InterestIncomeFromSecuritiesFinancingTransactionsMeasuredAtAmortizedCost": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "InterestIncomeFromSecuritiesFinancingTransactionsMeasuredAtAmortizedCost",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/NetInterestIncomeDetail": {
       "parentTag": "ifrs-full_InterestIncomeForFinancialAssetsNotAtFairValueThroughProfitOrLoss",
       "weight": 1.0,
       "order": 3.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/NetInterestIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest Income From Securities Financing Transactions Measured At Amortized Cost",
        "terseLabel": "Interest income from securities financing transactions measured at amortized cost",
        "documentation": "The amount of interest income on securities borrowed and reverse repurchase agreements and negative interest, including fees, on securities lent and repurchase agreements."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_InterestPaidClassifiedAsOperatingActivities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "InterestPaidClassifiedAsOperatingActivities",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest Paid Classified As Operating Activities",
        "terseLabel": "Interest paid in cash"
       }
      },
      "en": {
       "role": {
        "documentation": "The cash outflow for interest paid, classified as operating activities."
       }
      }
     },
     "auth_ref": [
      "r77"
     ]
    },
    "ifrs-full_InterestPayable": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "InterestPayable",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/OtherFinancialLiabilitiesMeasuredAtAmortizedCostDetail": {
       "parentTag": "ubsag_OtherFinancialLiabilitiesAtAmortisedCost",
       "weight": 1.0,
       "order": 3.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherFinancialLiabilitiesMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest Payable",
        "terseLabel": "Accrued interest expenses"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of interest recognised as a liability."
       }
      }
     },
     "auth_ref": [
      "r247"
     ]
    },
    "ubsag_InterestRateContractsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "InterestRateContractsMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail",
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "This member relates to interest rate contracts.",
        "terseLabel": "Interest rate contracts",
        "label": "Interest Rate Contracts [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_InterestRateContractsNetMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "InterestRateContractsNetMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsSensitivityToChangesInUnobservableInputAssumptionsDetail",
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest Rate Contracts Net [Member]",
        "terseLabel": "Interest rate derivative contracts, net",
        "documentation": "This member relates to interest rate derivative contracts, net.",
        "verboseLabel": "Derivative financial instruments: Interest rate contracts"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_InterestRateMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "InterestRateMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementComparisonOfShockFactorsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest Rate Member [Member]",
        "verboseLabel": "Fixed income: 10-year government bonds (%, Q4)",
        "documentation": "This member stands for 10-year government bonds yield."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_InterestRateRiskMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "InterestRateRiskMember",
     "presentation": [
      "http://www.ubsag.com/role/DerivativeInstrumentsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest Rate Risk [Member]",
        "terseLabel": "Fair value hedges of interest rate risk",
        "verboseLabel": "Interest rate",
        "commentaryGuidance": "Interest rates"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for the type of risk that the fair value or future cash flows of a financial instrument will fluctuate because of changes in market interest rates. [Refer: Financial instruments, class [member]]"
       }
      }
     },
     "auth_ref": [
      "r121",
      "r122",
      "r123",
      "r124",
      "r171"
     ]
    },
    "ifrs-full_InterestReceivable": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "InterestReceivable",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/OtherFinancialAssetsMeasuredAtAmortizedCostDetail": {
       "parentTag": "ubsag_OtherFinancialAssetsAtAmortisedCost",
       "weight": 1.0,
       "order": 7.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherFinancialAssetsMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest Receivable",
        "terseLabel": "Accrued interest income"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of interest recognised as a receivable."
       }
      }
     },
     "auth_ref": [
      "r247"
     ]
    },
    "ifrs-full_InterestReceivedClassifiedAsOperatingActivities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "InterestReceivedClassifiedAsOperatingActivities",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest Received Classified As Operating Activities",
        "terseLabel": "Interest received in cash"
       }
      },
      "en": {
       "role": {
        "documentation": "The cash inflow from interest received, classified as operating activities."
       }
      }
     },
     "auth_ref": [
      "r77"
     ]
    },
    "ifrs-full_InterestRevenueExpense": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "InterestRevenueExpense",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/SegmentReportingDetail": {
       "parentTag": "ifrs-full_Revenue",
       "weight": 1.0,
       "order": 2.0
      },
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement": {
       "parentTag": "ifrs-full_RevenueAndOperatingIncome",
       "weight": 1.0,
       "order": 5.0
      },
      "http://www.ubsag.com/role/NetInterestIncomeDetail": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement",
      "http://www.ubsag.com/role/NetInterestIncomeDetail",
      "http://www.ubsag.com/role/SegmentReportingDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "totalLabel": "Total net interest income",
        "label": "Interest Revenue Expense",
        "terseLabel": "Net interest income"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of income or expense arising from interest. [Refer: Interest expense; Interest income]"
       }
      }
     },
     "auth_ref": [
      "r176",
      "r182",
      "r252"
     ]
    },
    "ubsag_IntragroupFundingAtAmortisedCost": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "IntragroupFundingAtAmortisedCost",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_FinancialLiabilitiesAtAmortisedCost",
       "weight": 1.0,
       "order": 28.0
      },
      "http://www.ubsag.com/role/FundingFromGroupMeasuredAtAmortizedCostDetail": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/FVMFinancialInstrumentsNotMeasuredAtFairValueLiabilitiesDetail",
      "http://www.ubsag.com/role/FundingFromGroupMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Intragroup Funding At Amortised Cost",
        "documentation": "The amount of intra-group funding measured at amortized cost.",
        "terseLabel": "Funding from UBS Group AG measured at amortized cost",
        "totalLabel": "Total"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_IntragroupFundingAtAmortisedCostTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "IntragroupFundingAtAmortisedCostTransferredAsOfTheMergerDate",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Intragroup Funding At Amortised Cost Transferred As Of The Merger Date",
        "terseLabel": "Funding from UBS Group AG measured at amortized cost",
        "documentation": "The amount of intra-group funding measured at amortized cost."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_IntragroupFundingAtFairValue": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "IntragroupFundingAtFairValue",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/OtherFinancialLiabilitiesDesignatedAtFairValueDetail": {
       "parentTag": "ubsag_OtherFinancialLiabilitiesAtFairValueThroughProfitOrLossDesignatedAsUponInitialRecognition",
       "weight": 1.0,
       "order": 5.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherFinancialLiabilitiesDesignatedAtFairValueDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Intragroup Funding At Fair Value",
        "documentation": "The amount of intra-group funding designated at fair value.",
        "terseLabel": "Funding from UBS Group AG"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_IntragroupFundingMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "IntragroupFundingMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Intragroup Funding Member [Member]",
        "terseLabel": "Funding from UBS Group AG",
        "documentation": "This member refers to intra-group funding."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_InvestmentAccountedForUsingEquityMethod": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "InvestmentAccountedForUsingEquityMethod",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_Assets",
       "weight": 1.0,
       "order": 17.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Investment Accounted For Using Equity Method",
        "periodStartLabel": "Carrying amount at the beginning of the year",
        "periodEndLabel": "Carrying amount at the end of the year",
        "terseLabel": "Investments in subsidiaries and associates",
        "verboseLabel": "Investments in associates"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of investments accounted for using the equity method. The equity method is a method of accounting whereby the investment is initially recognised at cost and adjusted thereafter for the post-acquisition change in the investor's share of net assets of the investee. The investor's profit or loss includes its share of the profit or loss of the investee. The investor's other comprehensive income includes its share of the other comprehensive income of the investee. [Refer: At cost [member]]"
       }
      }
     },
     "auth_ref": [
      "r9",
      "r96",
      "r177"
     ]
    },
    "ubsag_InvestmentAccountedForUsingEquityMethodTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "InvestmentAccountedForUsingEquityMethodTransferredAsOfTheMergerDate",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Investment Accounted For Using Equity Method Transferred As Of The Merger Date",
        "terseLabel": "Investments in associates",
        "documentation": "The amount of investments accounted for using the equity method. The equity method is a method of accounting whereby the investment is initially recognised at cost and adjusted thereafter for the post-acquisition change in the investor's share of net assets of the investee. The investor's profit or loss includes its share of the profit or loss of the investee. The investor's other comprehensive income includes its share of the other comprehensive income of the investee. [Refer: At cost [member]]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_InvestmentFundFees": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "InvestmentFundFees",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail": {
       "parentTag": "ifrs-full_FeeAndCommissionIncome",
       "weight": 1.0,
       "order": 5.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Investment Fund Fees",
        "terseLabel": "Investment fund fees",
        "documentation": "The amount of investment fund fees."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_InvestmentFundsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "InvestmentFundsMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail",
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail",
      "http://www.ubsag.com/role/FVMLevel3InstrumentsSensitivityToChangesInUnobservableInputAssumptionsDetail",
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Investment funds",
        "terseLabel": "Investment fund units",
        "verboseLabel": "Financial assets and liabilities at fair value held for trading, Financial assets at fair value not held for trading: Investment fund units"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for investment funds."
       }
      }
     },
     "auth_ref": [
      "r209"
     ]
    },
    "ubsag_IrrevocableCommittedProlongationOfLoansMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "IrrevocableCommittedProlongationOfLoansMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Irrevocable Committed Prolongation Of Loans [Member]",
        "terseLabel": "Irrevocable committed prolongation of existing loans",
        "documentation": "This member relates to irrevocable committed prolongation of existing loans."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_IssueOfEquity": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "IssueOfEquity",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Issue Of Equity",
        "terseLabel": "Issuance of share capital"
       }
      },
      "en": {
       "role": {
        "documentation": "The increase in equity through the issue of equity instruments."
       }
      }
     },
     "auth_ref": [
      "r4"
     ]
    },
    "ifrs-full_IssuedCapital": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "IssuedCapital",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_EquityAttributableToOwnersOfParent",
       "weight": 1.0,
       "order": 42.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Issued Capital",
        "terseLabel": "Share capital"
       }
      },
      "en": {
       "role": {
        "documentation": "The nominal value of capital issued."
       }
      }
     },
     "auth_ref": [
      "r199"
     ]
    },
    "ubsag_IssuedCapitalAndSharePremiumMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "IssuedCapitalAndSharePremiumMember",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity",
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquityParenthetical"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Issued Capital And Share Premium [Member]",
        "terseLabel": "Share capital and share premium",
        "documentation": "This member stands for a component of equity representing issued capital and the amount received or receivable from issuance of the entity's shares in excess of nominal value."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_IssuedDebtInstrumentsAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "IssuedDebtInstrumentsAbstract",
     "presentation": [
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Issued Debt Instruments [Abstract]",
        "terseLabel": "Issued debt instruments"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_IssuesFairValueMeasurementAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "IssuesFairValueMeasurementAssets",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Issues Fair Value Measurement Assets",
        "terseLabel": "Issuances"
       }
      },
      "en": {
       "role": {
        "documentation": "The increase in the fair value measurement of assets resulting from issues of those assets. [Refer: At fair value [member]]"
       }
      }
     },
     "auth_ref": [
      "r101"
     ]
    },
    "ifrs-full_IssuesFairValueMeasurementLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "IssuesFairValueMeasurementLiabilities",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Issues Fair Value Measurement Liabilities",
        "terseLabel": "Issuances"
       }
      },
      "en": {
       "role": {
        "documentation": "The increase in fair value measurement of liabilities resulting from issues of those liabilities. [Refer: At fair value [member]]"
       }
      }
     },
     "auth_ref": [
      "r101"
     ]
    },
    "ubsag_JPYCurrencyExchangeRateMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "JPYCurrencyExchangeRateMember",
     "presentation": [
      "http://www.ubsag.com/role/BasisOfAccountingCurrencyTranslationRatesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "JPY Currency Exchange Rate [Member]",
        "terseLabel": "100 JPY",
        "documentation": "This member stands for currency translation rate of 100 JPY to the presentation currency."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_JointAndSeveralLiability": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "JointAndSeveralLiability",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/SupplementalGuarantorInformationNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Joint And Several Liability",
        "terseLabel": "Joint and several liability",
        "documentation": "The joint liability for contractual obligations of UBS AG amounts to."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_JointAndSeveralLiabilityForOutstandingSecRegisteredDebtSecuritiesIssuedByIndirectSubsidiary": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "JointAndSeveralLiabilityForOutstandingSecRegisteredDebtSecuritiesIssuedByIndirectSubsidiary",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/SupplementalGuarantorInformationNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Joint and Several Liability For Outstanding SEC Registered Debt Securities Issued By Indirect Subsidiary",
        "terseLabel": "Joint and several liability for outstanding SEC-registered debt securities issued by Credit Suisse (USA), Inc.",
        "documentation": "The amount of outstanding SEC-registered debt securities issued by Credit Suisse (USA), Inc., that has been fully and unconditionally guaranteed by UBS AG and UBS Group AG."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_LaterThanOneYearAndNotLaterThanTwoYearsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "LaterThanOneYearAndNotLaterThanTwoYearsMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementComparisonOfShockFactorsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Later Than One Year And Not Later Than Two Years [Member]",
        "terseLabel": "2025"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a time band of later than one year and not later than two years."
       }
      }
     },
     "auth_ref": [
      "r116",
      "r117",
      "r127",
      "r231",
      "r238",
      "r247"
     ]
    },
    "ifrs-full_LeaseLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "LeaseLiabilities",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/OtherFinancialLiabilitiesMeasuredAtAmortizedCostDetail": {
       "parentTag": "ubsag_OtherFinancialLiabilitiesAtAmortisedCost",
       "weight": 1.0,
       "order": 5.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherFinancialLiabilitiesMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Lease Liabilities",
        "terseLabel": "Lease liabilities",
        "verboseLabel": "Carrying amount of total lease liabilities as of 1 January 2019"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of liabilities related to the entity's leases. Lease is a contract, or part of a contract, that conveys the right to use an underlying asset for a period of time in exchange for consideration."
       }
      }
     },
     "auth_ref": [
      "r114"
     ]
    },
    "dei_LegalEntityAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "http://xbrl.sec.gov/dei/2023",
     "localname": "LegalEntityAxis",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAG",
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail",
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGTables",
      "http://www.ubsag.com/role/BasisOfAccounting",
      "http://www.ubsag.com/role/BasisOfAccountingCurrencyTranslationRatesDetail",
      "http://www.ubsag.com/role/BasisOfAccountingNarrativeDetail",
      "http://www.ubsag.com/role/BasisOfAccountingPolicy",
      "http://www.ubsag.com/role/BasisOfAccountingTables",
      "http://www.ubsag.com/role/ChangesInAccountingPoliciesComparabilityAndAdjustments",
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement",
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows",
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlowsParenthetical",
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity",
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquityParenthetical",
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome",
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncomeParenthetical",
      "http://www.ubsag.com/role/CurrencyTranslationRates",
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValue",
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueDetail",
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueTable",
      "http://www.ubsag.com/role/DebtIssuedHeldAtAmortizedCost",
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostDetail",
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostTables",
      "http://www.ubsag.com/role/DerivativeInstruments",
      "http://www.ubsag.com/role/DerivativeInstrumentsDetail",
      "http://www.ubsag.com/role/DerivativeInstrumentsTables",
      "http://www.ubsag.com/role/DocumentAndEntityInformation",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurement",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementChangesToECLModelsScenariosScenarioWeightsAndPostmodelAdjustmentsNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementComparisonOfShockFactorsDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpenseReleaseNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpensereleaseDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementECLrelevantBalanceSheetAndOffbalanceSheetPositionsIncludingECLAllowancesAndProvisionsNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementEconomicScenariosAndWeightsAppliedDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementTables",
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail",
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail",
      "http://www.ubsag.com/role/FVMFairValueMeasurementNarrativeDetail",
      "http://www.ubsag.com/role/FVMFinancialInstrumentsNotMeasuredAtFairValueAssetsDetail",
      "http://www.ubsag.com/role/FVMFinancialInstrumentsNotMeasuredAtFairValueLiabilitiesDetail",
      "http://www.ubsag.com/role/FVMLevel3InstrumentsSensitivityToChangesInUnobservableInputAssumptionsDetail",
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail",
      "http://www.ubsag.com/role/FVMValuationAdjustmentsDeferredDay1PLDetail",
      "http://www.ubsag.com/role/FVMValuationAdjustmentsReservesOnTheBalanceSheetDetail",
      "http://www.ubsag.com/role/FairValueMeasurement",
      "http://www.ubsag.com/role/FairValueMeasurementTables",
      "http://www.ubsag.com/role/FundingFromGroupMeasuredAtAmortizedCost",
      "http://www.ubsag.com/role/FundingFromGroupMeasuredAtAmortizedCostDetail",
      "http://www.ubsag.com/role/FundingFromGroupMeasuredAtAmortizedCostTables",
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpenses",
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesDetail",
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesTables",
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMatters",
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersDetail",
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail",
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersTables",
      "http://www.ubsag.com/role/NetFeeAndCommissionIncome",
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail",
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeTables",
      "http://www.ubsag.com/role/NetInterestIncome",
      "http://www.ubsag.com/role/NetInterestIncomeDetail",
      "http://www.ubsag.com/role/NetInterestIncomeTables",
      "http://www.ubsag.com/role/OffsettingFinancialAssetsDetail",
      "http://www.ubsag.com/role/OffsettingFinancialLiabilitiesDetail",
      "http://www.ubsag.com/role/OtherAssetsAndLiabilities",
      "http://www.ubsag.com/role/OtherAssetsAndLiabilitiesTables",
      "http://www.ubsag.com/role/OtherFinancialAssetsMeasuredAtAmortizedCostDetail",
      "http://www.ubsag.com/role/OtherFinancialLiabilitiesDesignatedAtFairValueDetail",
      "http://www.ubsag.com/role/OtherFinancialLiabilitiesMeasuredAtAmortizedCostDetail",
      "http://www.ubsag.com/role/OtherIncome",
      "http://www.ubsag.com/role/OtherIncomeDetail",
      "http://www.ubsag.com/role/OtherIncomeTables",
      "http://www.ubsag.com/role/OtherNonfinancialAssetsDetail",
      "http://www.ubsag.com/role/OtherNonfinancialLiabilitiesDetail",
      "http://www.ubsag.com/role/PersonnelExpenses",
      "http://www.ubsag.com/role/PersonnelExpensesDetail",
      "http://www.ubsag.com/role/PersonnelExpensesTables",
      "http://www.ubsag.com/role/Provisions",
      "http://www.ubsag.com/role/ProvisionsAdditionalInformationDetail",
      "http://www.ubsag.com/role/ProvisionsAndContingentLiabilitiesTables",
      "http://www.ubsag.com/role/ProvisionsDetail",
      "http://www.ubsag.com/role/ReclassificationOfFinancialAssetsNarrativeDetail",
      "http://www.ubsag.com/role/SegmentReporting",
      "http://www.ubsag.com/role/SegmentReportingDetail",
      "http://www.ubsag.com/role/SegmentReportingNarrativeDetail",
      "http://www.ubsag.com/role/SegmentReportingTables",
      "http://www.ubsag.com/role/SupplementalGuarantorConsolidatedStatementOfCashFlowsDetail",
      "http://www.ubsag.com/role/SupplementalGuarantorInformationNarrativeDetail",
      "http://www.ubsag.com/role/SupplementalGuarantorInformationRequiredUnderSECRegulations"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Legal Entity [Axis]",
        "documentation": "The set of legal entities associated with a report."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_LegalProceedingsProvision": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "LegalProceedingsProvision",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Legal Proceedings Provision",
        "terseLabel": "Provision recorded to cover pending legal case"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of provision for legal proceedings. [Refer: Other provisions]"
       }
      }
     },
     "auth_ref": [
      "r206",
      "r207"
     ]
    },
    "ifrs-full_LegalProceedingsProvisionMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "LegalProceedingsProvisionMember",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersDetail",
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail",
      "http://www.ubsag.com/role/ProvisionsAdditionalInformationDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "terseLabel": "Litigation, regulatory and similar matters",
        "label": "Legal Proceedings Provision [Member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a provision for legal proceedings. [Refer: Other provisions [member]]"
       }
      }
     },
     "auth_ref": [
      "r206",
      "r207"
     ]
    },
    "ifrs-full_Level1OfFairValueHierarchyMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "Level1OfFairValueHierarchyMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail",
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Level 1 Of Fair Value Hierarchy [Member]",
        "terseLabel": "Level 1",
        "verboseLabel": "Quoted in active market"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a category of the fair value hierarchy where inputs to the valuation techniques are quoted prices (unadjusted) in active markets for identical assets or liabilities that the entity can access at the measurement date."
       }
      }
     },
     "auth_ref": [
      "r44",
      "r98"
     ]
    },
    "ifrs-full_Level2OfFairValueHierarchyMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "Level2OfFairValueHierarchyMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail",
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Level 2 Of Fair Value Hierarchy [Member]",
        "terseLabel": "Level 2"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a category of the fair value hierarchy where inputs to the valuation techniques are inputs other than quoted prices included within Level 1 that are observable for the asset or liability, either directly or indirectly."
       }
      }
     },
     "auth_ref": [
      "r98"
     ]
    },
    "ifrs-full_Level3OfFairValueHierarchyMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "Level3OfFairValueHierarchyMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail",
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail",
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Level 3 Of Fair Value Hierarchy [Member]",
        "terseLabel": "Level 3"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a category of the fair value hierarchy where inputs to the valuation techniques are unobservable inputs for the asset or liability. Unobservable inputs are inputs for which market data are not available and that are developed using the best information available about the assumptions that the market participants would use when pricing the asset or liability."
       }
      }
     },
     "auth_ref": [
      "r98"
     ]
    },
    "ifrs-full_LevelsOfFairValueHierarchyAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "LevelsOfFairValueHierarchyAxis",
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail",
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail",
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Levels Of Fair Value Hierarchy [Axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r44",
      "r98"
     ]
    },
    "ifrs-full_Liabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "Liabilities",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_EquityAndLiabilities",
       "weight": 1.0,
       "order": 40.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Liabilities",
        "totalLabel": "Total liabilities",
        "terseLabel": "Total liabilities measured at fair value",
        "verboseLabel": "Total liabilities recognized on the balance sheet",
        "positiveTerseLabel": "Total liabilities"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of a present obligation of the entity to transfer an economic resource as a result of past events. Economic resource is a right that has the potential to produce economic benefits."
       }
      }
     },
     "auth_ref": [
      "r16",
      "r97",
      "r98",
      "r103",
      "r176",
      "r181"
     ]
    },
    "ifrs-full_LiabilitiesAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "LiabilitiesAbstract",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail",
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Liabilities [Abstract]",
        "terseLabel": "Liabilities",
        "verboseLabel": "Total liabilities"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_LiabilitiesAfterConsiderationOfNettingPotential": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "LiabilitiesAfterConsiderationOfNettingPotential",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/OffsettingFinancialLiabilitiesDetail": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OffsettingFinancialLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Liabilities After Consideration Of Netting Potential",
        "totalLabel": "Liabilities, after consideration of further netting potential",
        "documentation": "The amount of liabilities after consideration of netting potential."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_LiabilitiesAtFairValueTransferred": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "LiabilitiesAtFairValueTransferred",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Liabilities At Fair Value Transferred",
        "terseLabel": "Effect from a business combination",
        "documentation": "The amount of liabilities measured at fair value transferred in a business combination."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_LiabilitiesTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "LiabilitiesTransferredAsOfTheMergerDate",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Liabilities Transferred As Of The Merger Date",
        "terseLabel": "Total liabilities",
        "documentation": "The amount of a present obligation of the entity to transfer an economic resource as a result of past events. Economic resource is a right that has the potential to produce economic benefits."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_LifeToDateChangeInFairValueOfFinancialLiabilityAttributableToChangeInCreditRiskOfLiabilityIssuedDebt": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "LifeToDateChangeInFairValueOfFinancialLiabilityAttributableToChangeInCreditRiskOfLiabilityIssuedDebt",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Life To Date Change In Fair Value Of Financial Liability Attributable To Change In Credit Risk Of Liability Issued Debt",
        "negatedLabel": "of which: life-to-date own credit (gain) / loss",
        "documentation": "The amount of life-to-credit own credit (gain) / loss of financial liabilities at fair value through profit or loss that were designated as such upon initial recognition or subsequently. A negative value refers to life-to-date gain whereas a positive value refers to life-to-date loss."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_LifetimeExpectedCreditLossesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "LifetimeExpectedCreditLossesMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpenseReleaseNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpensereleaseDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Lifetime Expected Credit Losses [Member]",
        "terseLabel": "Lifetime expected credit losses"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for the expected credit losses that result from all possible default events over the expected life of a financial instrument. [Refer: Type of measurement of expected credit losses [member]]"
       }
      }
     },
     "auth_ref": [
      "r149",
      "r156"
     ]
    },
    "ubsag_LiquidityValuationAdjustments": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "LiquidityValuationAdjustments",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/FVMValuationAdjustmentsReservesOnTheBalanceSheetDetail": {
       "parentTag": "ubsag_OtherValuationAdjustments",
       "weight": 1.0,
       "order": 8.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/FVMValuationAdjustmentsReservesOnTheBalanceSheetDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Liquidity Valuation Adjustments",
        "terseLabel": "of which: liquidity",
        "documentation": "The amount of valuation adjustments made on financial instruments relating to liquidity."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_LitigationAgreedSettlementPendingApproval": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "LitigationAgreedSettlementPendingApproval",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Litigation Agreed Settlement Pending Approval",
        "terseLabel": "Agreed settlement pending approval",
        "documentation": "The amount of agreed settlement pending court approval."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_LitigationRegulatoryAndSimilarMattersAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "LitigationRegulatoryAndSimilarMattersAxis",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Litigation Regulatory And Similar Matters [Axis]",
        "documentation": "The axis of a table defines the relationship between the domain members or categories in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_LitigationRegulatoryAndSimilarMattersMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "LitigationRegulatoryAndSimilarMattersMember",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Litigation Regulatory And Similar Matters [Member]",
        "documentation": "This member refers to all litigation, regulatory and similar matters."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_LoanCommitmentsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "LoanCommitmentsMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail",
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail",
      "http://www.ubsag.com/role/FVMLevel3InstrumentsSensitivityToChangesInUnobservableInputAssumptionsDetail",
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Loan commitments",
        "verboseLabel": "Irrevocable loan commitments",
        "terseLabel": "Loan commitments measured at FVTPL"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for firm commitments to provide credit under pre-specified terms and conditions."
       }
      }
     },
     "auth_ref": [
      "r158",
      "r170"
     ]
    },
    "ubsag_LoanPriceEquivalentMeasurementInputMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "LoanPriceEquivalentMeasurementInputMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Loan Price Equivalent Measurement Input [Member]",
        "terseLabel": "Loan price equivalent (% of par)",
        "documentation": "This member stands for loan price equivalent used as a significant Level 3 unobservable input."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_LoansAndAdvancesToBanks": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "LoansAndAdvancesToBanks",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_FinancialAssetsAtAmortisedCost",
       "weight": 1.0,
       "order": 4.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/FVMFinancialInstrumentsNotMeasuredAtFairValueAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Loans And Advances To Banks",
        "totalLabel": "Due from banks, net",
        "terseLabel": "Loans and advances to banks",
        "verboseLabel": "Amounts due from banks"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of loans and advances the entity has made to banks."
       }
      }
     },
     "auth_ref": [
      "r249"
     ]
    },
    "ubsag_LoansAndAdvancesToBanksMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "LoansAndAdvancesToBanksMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Loans And Advances To Banks [Member]",
        "terseLabel": "Amounts due from banks",
        "documentation": "This member relates to loans and advances to banks.",
        "verboseLabel": "Amounts due from banks"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_LoansAndAdvancesToBanksTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "LoansAndAdvancesToBanksTransferredAsOfTheMergerDate",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Loans And Advances To Banks Transferred As Of The Merger Date",
        "terseLabel": "Amounts due from banks",
        "documentation": "The amount of loans and advances the entity has made to banks."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_LoansAndAdvancesToCustomers": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "LoansAndAdvancesToCustomers",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_FinancialAssetsAtAmortisedCost",
       "weight": 1.0,
       "order": 7.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/FVMFinancialInstrumentsNotMeasuredAtFairValueAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Loans And Advances To Customers",
        "totalLabel": "Loans, net",
        "terseLabel": "Loans and advances to customers",
        "verboseLabel": "Loans and advances to customers (formerly: Loans)",
        "positiveTerseLabel": "Total"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of loans and advances the entity has made to customers."
       }
      }
     },
     "auth_ref": [
      "r249"
     ]
    },
    "ubsag_LoansAndAdvancesToCustomersMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "LoansAndAdvancesToCustomersMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail",
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Loans And Advances To Customers [Member]",
        "terseLabel": "Loans",
        "documentation": "This member relates to loans and advances the entity has made to customers.",
        "verboseLabel": "Loans and advances to customers"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_LoansAndAdvancesToCustomersTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "LoansAndAdvancesToCustomersTransferredAsOfTheMergerDate",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Loans And Advances To Customers Transferred As Of The Merger Date",
        "terseLabel": "Loans and advances to customers",
        "documentation": "The amount of loans and advances the entity has made to customers."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_LoansToFinancialAdvisorsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "LoansToFinancialAdvisorsMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Loans To Financial Advisors [Member]",
        "terseLabel": "Loans to financial advisors",
        "documentation": "This member relates to loans to financial advisors.",
        "verboseLabel": "of which: Loans to financial advisors"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_LombardLoanMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "LombardLoanMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Lombard Loan [Member]",
        "terseLabel": "Lombard",
        "documentation": "This member relates to loan to purchase securities in which the security itself serves as collateral for the loan.",
        "verboseLabel": "of which: Lombard"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_LongTermDebtIssuedThroughCentralBondInstitutionsSwiss": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "LongTermDebtIssuedThroughCentralBondInstitutionsSwiss",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostDetail": {
       "parentTag": "ifrs-full_NoncurrentDebtInstrumentsIssued",
       "weight": 1.0,
       "order": 9.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Long Term Debt Issued Through Central Bond Institutions Swiss",
        "terseLabel": "Debt issued through the Swiss central mortgage institutions",
        "documentation": "The amount of debt issued through the central bond institutions of the Swiss regional or cantonal banks"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_LongTermDebtIssuedThroughCentralBondInstitutionsSwissSecuredPortion": {
     "xbrltype": "percentItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "LongTermDebtIssuedThroughCentralBondInstitutionsSwissSecuredPortion",
     "presentation": [
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Long Term Debt Issued Through Central Bond Institutions Swiss Secured Portion",
        "documentation": "The percentage for secured portion of Debt issued through the Swiss central mortgage institutions.",
        "terseLabel": "Secured portion of Debt issued through the Swiss central mortgage institutions"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_LossContingencyDamagesSoughtValue": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "LossContingencyDamagesSoughtValue",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Loss Contingency Damages Sought Value",
        "terseLabel": "Amounts claimed",
        "documentation": "The value (monetary amount) of the award the plaintiff seeks in the legal matter."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_LossesOnLitigationSettlements": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "LossesOnLitigationSettlements",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Losses On Litigation Settlements",
        "terseLabel": "Settlement made"
       }
      },
      "en": {
       "role": {
        "documentation": "The losses on settlements of litigation."
       }
      }
     },
     "auth_ref": [
      "r35"
     ]
    },
    "ubsag_MACorporateFinanceFees": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "MACorporateFinanceFees",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail": {
       "parentTag": "ifrs-full_FeeAndCommissionIncome",
       "weight": 1.0,
       "order": 3.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "MA Corporate Finance Fees",
        "terseLabel": "M&amp;A and corporate finance fees",
        "documentation": "The amount of fee income arising from merger and acquisition and corporate finance transactions."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_MadoffBMISTrusteeMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "MadoffBMISTrusteeMember",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Madoff BMIS Trustee [Member]",
        "terseLabel": "Madoff | claims filed in the US by BMIS Trustee against UBS entities and various other parties",
        "documentation": "This member refers to claims related to Bernard L. Madoff Investment Securities LLC (BMIS) Trustee investment fraud filed in the US."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_MadoffLuxembourgMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "MadoffLuxembourgMember",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Madoff Luxembourg [Member]",
        "terseLabel": "Madoff | claims filed in Luxembourg by liquidators of two Luxembourg funds against UBS entities, non-UBS entities and certain individuals",
        "documentation": "This member refers to claims related to Bernard L. Madoff Investment Securities LLC (BMIS) investment fraud filed in Luxembourg."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_MarketComparableAndSecuritizationModelMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "MarketComparableAndSecuritizationModelMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Market Comparable And Securitization Model [Member]",
        "terseLabel": "Market comparable and securitization model",
        "documentation": "This member stands for a specific valuation technique consistent with the market approach and available securitization model."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_MarketComparablePricesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "MarketComparablePricesMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Market Comparable Prices [Member]",
        "terseLabel": "Relative value to market comparable"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a specific valuation technique consistent with the market approach that involves analysing inputs from comparable prices (for example, price per square metre) in the current market. [Refer: Market approach [member]]"
       }
      }
     },
     "auth_ref": [
      "r215",
      "r218"
     ]
    },
    "ubsag_MarketDataServicesExpense": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "MarketDataServicesExpense",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesDetail": {
       "parentTag": "ifrs-full_GeneralAndAdministrativeExpense",
       "weight": 1.0,
       "order": 6.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Market Data Services Expense",
        "terseLabel": "Market data services",
        "documentation": "The amount of expense relating to market data services."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_MaturityAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "MaturityAxis",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementComparisonOfShockFactorsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Maturity [Axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r19",
      "r113",
      "r116",
      "r117",
      "r118",
      "r119",
      "r120",
      "r127",
      "r142",
      "r160",
      "r204",
      "r231"
     ]
    },
    "ifrs-full_MeasurementAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "MeasurementAxis",
     "presentation": [
      "http://www.ubsag.com/role/FVMFinancialInstrumentsNotMeasuredAtFairValueAssetsDetail",
      "http://www.ubsag.com/role/FVMFinancialInstrumentsNotMeasuredAtFairValueLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Measurement [Axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r65",
      "r69",
      "r97"
     ]
    },
    "ubsag_MergerWithCreditSuisseAGMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "MergerWithCreditSuisseAGMember",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail",
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity",
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquityParenthetical",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail",
      "http://www.ubsag.com/role/FVMValuationAdjustmentsDeferredDay1PLDetail",
      "http://www.ubsag.com/role/SegmentReportingNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Merger With Credit Suisse AG [Member]",
        "documentation": "This member stands for merger with Credit Suisse AG.",
        "terseLabel": "Merger with Credit Suisse AG"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_MildDownsideScenarioMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "MildDownsideScenarioMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementEconomicScenariosAndWeightsAppliedDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "terseLabel": "Mild debt crisis",
        "documentation": "This member stands for mild downside economic scenarios used in the calculation of expected credit losses.",
        "label": "Mild Downside Scenario [Member]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_MinimumTotalClaimsAgainstAllDefendants": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "MinimumTotalClaimsAgainstAllDefendants",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Minimum Total Claims Against All Defendants",
        "terseLabel": "Minimum total claims against all defendants",
        "documentation": "The minimum amount of total claims against all defendants."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_MiscellaneousOtherOperatingExpense": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "MiscellaneousOtherOperatingExpense",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesDetail": {
       "parentTag": "ifrs-full_GeneralAndAdministrativeExpense",
       "weight": 1.0,
       "order": 10.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Miscellaneous Other Operating Expense",
        "terseLabel": "Other"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of miscellaneous other operating expenses. [Refer: Other operating income (expense)]"
       }
      }
     },
     "auth_ref": [
      "r247"
     ]
    },
    "ifrs-full_MiscellaneousOtherProvisionsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "MiscellaneousOtherProvisionsMember",
     "presentation": [
      "http://www.ubsag.com/role/ProvisionsAdditionalInformationDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Miscellaneous Other Provisions [Member]",
        "terseLabel": "Other"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for miscellaneous other provisions. [Refer: Other provisions [member]]"
       }
      }
     },
     "auth_ref": [
      "r59"
     ]
    },
    "ubsag_ModelUncertaintyValuationAdjustments": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ModelUncertaintyValuationAdjustments",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/FVMValuationAdjustmentsReservesOnTheBalanceSheetDetail": {
       "parentTag": "ubsag_OtherValuationAdjustments",
       "weight": 1.0,
       "order": 9.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/FVMValuationAdjustmentsReservesOnTheBalanceSheetDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Model Uncertainty Valuation Adjustments",
        "terseLabel": "of which: model uncertainty",
        "documentation": "The amount of valuation adjustments made on financial instruments relating to model uncertainty."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_ModerateDownsideScenarioMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ModerateDownsideScenarioMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementEconomicScenariosAndWeightsAppliedDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Moderate Downside Scenario [Member]",
        "terseLabel": "Stagflationary geopolitical crisis",
        "documentation": "This member stands for moderate downside scenario used in the calculation of expected credit losses."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_MoneyMarketPaperInFinancialAssetsAtFairValueHeldForTrading": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "MoneyMarketPaperInFinancialAssetsAtFairValueHeldForTrading",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlowsParenthetical"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Money Market Paper In Financial Assets At Fair Value Held For Trading",
        "terseLabel": "Money market paper in financial assets at fair value held for trading",
        "documentation": "The amount in financial assets at fair value held for trading in the form of money market paper."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_MoneyMarketPaperInFinancialAssetsAtFairValueNotHeldForTrading": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "MoneyMarketPaperInFinancialAssetsAtFairValueNotHeldForTrading",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlowsParenthetical"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Money Market Paper In Financial Assets At Fair Value Not Held For Trading",
        "terseLabel": "Money market paper in financial assets at fair value not held for trading",
        "documentation": "The amount of financial assets at fair value not held for trading in the form of money market paper."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_MoneyMarketPaperInFinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncome": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "MoneyMarketPaperInFinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncome",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlowsParenthetical"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Money Market Paper In Financial Assets Measured At Fair Value Through Other Comprehensive Income",
        "terseLabel": "Money market paper in financial assets measured at fair value through other comprehensive income",
        "documentation": "The amount in financial assets measured at fair value through other comprehensive income in the form of money market paper."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_MoneyMarketPaperInOtherFinancialAssetsMeasuredAtAmortizedCost": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "MoneyMarketPaperInOtherFinancialAssetsMeasuredAtAmortizedCost",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlowsParenthetical"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Money Market Paper In Other Financial Assets Measured At Amortized Cost",
        "terseLabel": "Money market paper in other financial assets measured at amortized cost",
        "documentation": "The amount of other financial assets measured at amortized cost in the form of money market paper."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_MortgageRelatedMattersMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "MortgageRelatedMattersMember",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Mortgage Related Matters [Member]",
        "terseLabel": "Mortgage-related matters",
        "documentation": "This member refers to mortgage-related matters."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_MortgagesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "MortgagesMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Mortgages [Member]",
        "terseLabel": "Private clients with mortgages",
        "verboseLabel": "of which: Private clients with mortgages"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a class of financial assets that represents loans to finance the purchase of assets where the asset acts as collateral to secure the loan."
       }
      }
     },
     "auth_ref": [
      "r230",
      "r235",
      "r240"
     ]
    },
    "ifrs-full_NetAssetValueMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "NetAssetValueMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Net Asset Value [Member]",
        "terseLabel": "Net asset value"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a valuation technique that compares the value of assets and liabilities."
       }
      }
     },
     "auth_ref": [
      "r210",
      "r218"
     ]
    },
    "ubsag_NetBrokerageFees": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "NetBrokerageFees",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Net Brokerage Fees",
        "terseLabel": "of which: net brokerage fees",
        "documentation": "The net fee income/(expense) from brokerage transactions."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_NetFeeAndCommissionIncomeLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "NetFeeAndCommissionIncomeLineItems",
     "presentation": [
      "http://www.ubsag.com/role/NetFeeAndCommissionIncome",
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail",
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Net fee And Commission Income [Line Items]",
        "terseLabel": "Net fee and commission income",
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with domain members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_NetFinancialAssetsSubjectToOffsettingEnforceableMasterNettingArrangementsOrSimilarAgreementsInStatementOfFinancialPosition": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "NetFinancialAssetsSubjectToOffsettingEnforceableMasterNettingArrangementsOrSimilarAgreementsInStatementOfFinancialPosition",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/OffsettingFinancialAssetsDetail": {
       "parentTag": "ubsag_AssetsAfterConsiderationOfNettingPotential",
       "weight": 1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OffsettingFinancialAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Net Financial Assets Subject To Offsetting Enforceable Master Netting Arrangements Or Similar Agreements In Statement Of Financial Position",
        "totalLabel": "Net assets recognized on the balance sheet",
        "terseLabel": "Assets based on IFRS netting"
       }
      },
      "en": {
       "role": {
        "documentation": "The net amount of financial assets that are subject either to offsetting or to an enforceable master netting arrangement or similar agreement, presented in the statement of financial position. [Refer: Financial assets]"
       }
      }
     },
     "auth_ref": [
      "r135"
     ]
    },
    "ifrs-full_NetFinancialLiabilitiesSubjectToOffsettingEnforceableMasterNettingArrangementsOrSimilarAgreementsInStatementOfFinancialPosition": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "NetFinancialLiabilitiesSubjectToOffsettingEnforceableMasterNettingArrangementsOrSimilarAgreementsInStatementOfFinancialPosition",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/OffsettingFinancialLiabilitiesDetail": {
       "parentTag": "ubsag_LiabilitiesAfterConsiderationOfNettingPotential",
       "weight": 1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OffsettingFinancialLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Net Financial Liabilities Subject To Offsetting Enforceable Master Netting Arrangements Or Similar Agreements In Statement Of Financial Position",
        "totalLabel": "Net liabilities recognized on the balance sheet",
        "verboseLabel": "Liabilities based on IFRS netting"
       }
      },
      "en": {
       "role": {
        "documentation": "The net amount of financial liabilities that are subject either to offsetting or to an enforceable master netting arrangement or similar agreement, presented in the statement of financial position. [Refer: Financial liabilities]"
       }
      }
     },
     "auth_ref": [
      "r135"
     ]
    },
    "ubsag_NetInterestIncomeFromFinancialInstrumentsMeasuredAtAmortizedCostAndFairValueThroughOtherComprehensiveIncome": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "NetInterestIncomeFromFinancialInstrumentsMeasuredAtAmortizedCostAndFairValueThroughOtherComprehensiveIncome",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/NetInterestIncomeDetail": {
       "parentTag": "ifrs-full_InterestRevenueExpense",
       "weight": 1.0,
       "order": 13.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/NetInterestIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Net Interest Income From Financial Instruments Measured At Amortized Cost And Fair Value Through Other Comprehensive Income",
        "totalLabel": "Total net interest income from financial instruments measured at amortized cost and fair value through other comprehensive income",
        "documentation": "The total amount of net interest income from financial instruments measured at amortized cost and fair value through other comprehensive income"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_NetInterestIncomeFromFinancialInstrumentsMeasuredAtFairValueThroughProfitOrLossAndOther": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "NetInterestIncomeFromFinancialInstrumentsMeasuredAtFairValueThroughProfitOrLossAndOther",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement": {
       "parentTag": "ifrs-full_InterestRevenueExpense",
       "weight": 1.0,
       "order": 4.0
      },
      "http://www.ubsag.com/role/NetInterestIncomeDetail": {
       "parentTag": "ifrs-full_InterestRevenueExpense",
       "weight": 1.0,
       "order": 14.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement",
      "http://www.ubsag.com/role/NetInterestIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Interest Income Expense For Financial Instruments At Fair Value Through Profit Or Loss And Other",
        "documentation": "The amount of net interest income on financial instruments that are at fair value through profit or loss and other, excluding dividend income.",
        "terseLabel": "Net interest income from financial instruments measured at fair value through profit or loss and other",
        "totalLabel": "Total net interest income from financial instruments measured at fair value through profit or loss and other"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_NetInterestIncomeLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "NetInterestIncomeLineItems",
     "presentation": [
      "http://www.ubsag.com/role/NetInterestIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Net Interest Income [Line Items]",
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with domain members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_NetRedemptionPurchaseOfFinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncome": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "NetRedemptionPurchaseOfFinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncome",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInInvestingActivities",
       "weight": -1.0,
       "order": 31.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Net Redemption Purchase Of Financial Assets Measured At Fair Value Through Other Comprehensive Income",
        "terseLabel": "Net (purchase) / redemption of financial assets measured at fair value through other comprehensive income",
        "documentation": "The net amount of redemption/(purchase) of financial assets measured at fair value through other comprehensive income.",
        "negatedLabel": "Net (purchase) / redemption of financial assets measured at fair value through other comprehensive income"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_NetShortTermDebtIssuedRepaid": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "NetShortTermDebtIssuedRepaid",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInFinancingActivities",
       "weight": 1.0,
       "order": 37.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Net Short Term Debt Issued Repaid",
        "terseLabel": "Net short-term debt issued / (repaid)",
        "documentation": "The aggregate cash flows obtained from issuance of short term debt and (repayment of) short term debt issued.",
        "verboseLabel": "Net issuance (repayment) of short-term debt measured at amortized cost"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_NonCashItemsIncludedInNetProfitAndOtherAdjustmentsAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "NonCashItemsIncludedInNetProfitAndOtherAdjustmentsAbstract",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Non Cash Items Included In Net Profit And Other Adjustments [Abstract]",
        "terseLabel": "Non-cash items included in net profit and other adjustments:"
       }
      }
     },
     "auth_ref": []
    },
    "srt_NonGuarantorSubsidiariesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://fasb.org/srt/2023",
     "localname": "NonGuarantorSubsidiariesMember",
     "presentation": [
      "http://www.ubsag.com/role/SupplementalGuarantorConsolidatedStatementOfCashFlowsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Non Guarantor Subsidiaries [Member]",
        "terseLabel": "Other subsidiaries"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_NoncontrollingInterests": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "NoncontrollingInterests",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_Equity",
       "weight": 1.0,
       "order": 48.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Noncontrolling Interests",
        "terseLabel": "Equity attributable to non-controlling interests"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of equity in a subsidiary not attributable, directly or indirectly, to a parent. [Refer: Subsidiaries [member]]"
       }
      }
     },
     "auth_ref": [
      "r14",
      "r88",
      "r90"
     ]
    },
    "ifrs-full_NoncontrollingInterestsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "NoncontrollingInterestsMember",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity",
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquityParenthetical",
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Non-controlling Interests [Member]",
        "terseLabel": "Comprehensive income attributable to non-controlling interests",
        "verboseLabel": "Non-controlling interests"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for equity in a subsidiary not attributable, directly or indirectly, to the parent."
       }
      }
     },
     "auth_ref": [
      "r6"
     ]
    },
    "ubsag_NoncontrollingInterestsTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "NoncontrollingInterestsTransferredAsOfTheMergerDate",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Noncontrolling Interests Transferred As Of The Merger Date",
        "terseLabel": "Equity attributable to non-controlling interests",
        "documentation": "The amount of equity in a subsidiary not attributable, directly or indirectly, to a parent. [Refer: Subsidiaries [member]]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_NoncurrentDebtInstrumentsIssued": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "NoncurrentDebtInstrumentsIssued",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostDetail": {
       "parentTag": "ifrs-full_DebtSecurities",
       "weight": 1.0,
       "order": 11.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Noncurrent Debt Instruments Issued",
        "totalLabel": "Long-term debt"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of non-current debt instruments issued. [Refer: Debt instruments issued]"
       }
      }
     },
     "auth_ref": [
      "r249"
     ]
    },
    "ubsag_NoninterestIncome": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "NoninterestIncome",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/SegmentReportingDetail": {
       "parentTag": "ifrs-full_Revenue",
       "weight": 1.0,
       "order": 3.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/SegmentReportingDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Noninterest Income",
        "terseLabel": "Non-interest income",
        "documentation": "The total amount of noninterest income which may be derived from: (1) fees and commissions; (2) premiums earned; (3) insurance policy charges; (4) the sale or disposal of assets; and (5) other sources not otherwise specified."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_NotLaterThanOneYearMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "NotLaterThanOneYearMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementComparisonOfShockFactorsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Not Later Than One Year [Member]",
        "terseLabel": "Within 1 year",
        "verboseLabel": "2024"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a time band of not later than one year."
       }
      }
     },
     "auth_ref": [
      "r18",
      "r116",
      "r117",
      "r127",
      "r231",
      "r238"
     ]
    },
    "ifrs-full_NotMeasuredAtFairValueInStatementOfFinancialPositionButForWhichFairValueIsDisclosedMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "NotMeasuredAtFairValueInStatementOfFinancialPositionButForWhichFairValueIsDisclosedMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMFinancialInstrumentsNotMeasuredAtFairValueAssetsDetail",
      "http://www.ubsag.com/role/FVMFinancialInstrumentsNotMeasuredAtFairValueLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Not Measured At Fair Value In Statement Of Financial Position But For Which Fair Value Is Disclosed [Member]",
        "terseLabel": "Not measured at fair value"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for items not measured at fair value in the statement of financial position but for which fair value is disclosed. [Refer: At fair value [member]]"
       }
      }
     },
     "auth_ref": [
      "r106"
     ]
    },
    "ubsag_NotesLitigationRegulatoryAndSimilarMattersLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "NotesLitigationRegulatoryAndSimilarMattersLineItems",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Notes Litigation Regulatory And Similar Matters [Line Items]",
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with domain members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_NotionalAmountOfOtherDerivativeInstruments": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "NotionalAmountOfOtherDerivativeInstruments",
     "presentation": [
      "http://www.ubsag.com/role/DerivativeInstrumentsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Notional Amount Of Other Derivative Instruments",
        "terseLabel": "Other notional values",
        "documentation": "The gross nominal or face amount of derivative financial instruments, used to calculate payments made on that instrument, and which are cleared through a central clearing counterparty or an exchange."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OccupancyPropertyManagementExpense": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OccupancyPropertyManagementExpense",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesDetail": {
       "parentTag": "ifrs-full_GeneralAndAdministrativeExpense",
       "weight": 1.0,
       "order": 5.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Occupancy Property Management Expense",
        "terseLabel": "Real estate and logistics costs",
        "documentation": "The amount of expense arising from occupancy services received by the entity and relating to property management."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OffbalanceSheetLoanPortfolioMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OffbalanceSheetLoanPortfolioMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementECLrelevantBalanceSheetAndOffbalanceSheetPositionsIncludingECLAllowancesAndProvisionsNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Off-balance Sheet Loan Portfolio [Member]",
        "terseLabel": "Total",
        "documentation": "This member stands for total off-balance sheet loan portfolio."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OnBalanceSheetFinancialInstrumentsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OnBalanceSheetFinancialInstrumentsMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementECLrelevantBalanceSheetAndOffbalanceSheetPositionsIncludingECLAllowancesAndProvisionsNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "On Balance Sheet Financial Instruments [Member]",
        "terseLabel": "Total on-balance sheet financial assets in scope of ECL requirements",
        "verboseLabel": "Total on balance sheet financial instruments",
        "documentation": "This member relates to on-balance sheet financial instruments."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OnbalanceSheetLoanPortfolioMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OnbalanceSheetLoanPortfolioMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementECLrelevantBalanceSheetAndOffbalanceSheetPositionsIncludingECLAllowancesAndProvisionsNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "On-balance Sheet Loan Portfolio [Member]",
        "terseLabel": "Total",
        "documentation": "This member stands for total on-balance sheet loan portfolio."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_OneYearBeforeReportingYearMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "OneYearBeforeReportingYearMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementComparisonOfShockFactorsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "One Year Before Reporting Year [Member]",
        "terseLabel": "2023"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a year that ended one year before the end of the reporting year."
       }
      }
     },
     "auth_ref": [
      "r126"
     ]
    },
    "ifrs-full_OptionPricingModelMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "OptionPricingModelMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Option Pricing Model [Member]",
        "terseLabel": "Option model"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a specific valuation technique consistent with the income approach that involves analysing future amounts with option pricing models, such as the Black-Scholes-Merton formula or a binominal model (ie a lattice model), that incorporate present value techniques and reflect both the time value and intrinsic value of an option. [Refer: Income approach [member]]"
       }
      }
     },
     "auth_ref": [
      "r213",
      "r218"
     ]
    },
    "ifrs-full_OtherAdjustmentsForNoncashItems": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "OtherAdjustmentsForNoncashItems",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperatingActivities",
       "weight": 1.0,
       "order": 11.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "terseLabel": "Other net adjustments",
        "label": "Other Adjustments For Noncash Items"
       }
      },
      "en": {
       "role": {
        "documentation": "Adjustments for non-cash items to reconcile profit (loss) to net cash flow from (used in) operating activities that the entity does not separately disclose in the same statement or note. [Refer: Profit (loss)]"
       }
      }
     },
     "auth_ref": [
      "r258"
     ]
    },
    "ubsag_OtherAdjustmentsForWhichEffectsAreFinancingCashFlow": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherAdjustmentsForWhichEffectsAreFinancingCashFlow",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperatingActivities",
       "weight": 1.0,
       "order": 10.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "terseLabel": "Net loss / (gain) from financing activities",
        "label": "Other Adjustments For Which Effects Are Financing Cash Flow",
        "documentation": "Adjustments to reconcile profit (loss) to net cash flow from (used in) operating activities for which effects are financing cash flow, that the entity does not separately disclose in the same statement or note."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherAdjustmentsForWhichEffectsAreInvestingCashFlow": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherAdjustmentsForWhichEffectsAreInvestingCashFlow",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperatingActivities",
       "weight": 1.0,
       "order": 9.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Adjustments For Which Effects Are Investing Cash Flow",
        "documentation": "Adjustments to reconcile profit (loss) to net cash flow from (used in) operating activities for which effects are investing cash flow, that the entity does not separately disclose in the same statement or note.",
        "terseLabel": "Net loss / (gain) from investing activities"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_OtherAdjustmentsToReconcileProfitLoss": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "OtherAdjustmentsToReconcileProfitLoss",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperatingActivities",
       "weight": 1.0,
       "order": 22.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Adjustments To Reconcile Profit Loss",
        "terseLabel": "Provisions and other non-financial assets and liabilities"
       }
      },
      "en": {
       "role": {
        "documentation": "Adjustments to reconcile profit (loss) to net cash flow from (used in) operating activities that the entity does not separately disclose in the same statement or note. [Refer: Adjustments to reconcile profit (loss)]"
       }
      }
     },
     "auth_ref": [
      "r73"
     ]
    },
    "ubsag_OtherAssetsAndOtherLiabilitiesLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherAssetsAndOtherLiabilitiesLineItems",
     "presentation": [
      "http://www.ubsag.com/role/OtherAssetsAndLiabilities",
      "http://www.ubsag.com/role/OtherAssetsAndLiabilitiesTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Assets And Other Liabilities [Line Items]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherCompensationPlansLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherCompensationPlansLiabilities",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/OtherNonfinancialLiabilitiesDetail": {
       "parentTag": "ubsag_CompensationrelatedLiabilities",
       "weight": 1.0,
       "order": 5.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherNonfinancialLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Compensation Plans Liabilities",
        "terseLabel": "of which: other compensation plans",
        "documentation": "The amount of compensation-related liabilities related to other compensation plans."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherCompensationrelatedLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherCompensationrelatedLiabilities",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/OtherNonfinancialLiabilitiesDetail": {
       "parentTag": "ubsag_CompensationrelatedLiabilities",
       "weight": 1.0,
       "order": 7.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherNonfinancialLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Compensation-related Liabilities",
        "terseLabel": "of which: other compensation-related liabilities",
        "documentation": "The amount of other compensation-related liabilities."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_OtherComprehensiveIncome": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "OtherComprehensiveIncome",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity": {
       "parentTag": "ifrs-full_ComprehensiveIncome",
       "weight": 1.0,
       "order": 20.0
      },
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome": {
       "parentTag": "ifrs-full_ComprehensiveIncome",
       "weight": 1.0,
       "order": 34.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity",
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Comprehensive Income",
        "totalLabel": "Total other comprehensive income",
        "terseLabel": "Total other comprehensive income",
        "verboseLabel": "of which: OCI, net of tax"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of income and expense (including reclassification adjustments) that is not recognised in profit or loss as required or permitted by IFRSs. [Refer: IFRSs [member]]"
       }
      }
     },
     "auth_ref": [
      "r3",
      "r24",
      "r32",
      "r93"
     ]
    },
    "ifrs-full_OtherComprehensiveIncomeBeforeTaxChangeInFairValueOfFinancialLiabilityAttributableToChangeInCreditRiskOfLiability": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "OtherComprehensiveIncomeBeforeTaxChangeInFairValueOfFinancialLiabilityAttributableToChangeInCreditRiskOfLiability",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome": {
       "parentTag": "ifrs-full_OtherComprehensiveIncomeNetOfTaxChangeInFairValueOfFinancialLiabilityAttributableToChangeInCreditRiskOfLiability",
       "weight": 1.0,
       "order": 30.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome",
      "http://www.ubsag.com/role/FVMFairValueMeasurementNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Comprehensive Income Before Tax Change In Fair Value Of Financial Liability Attributable To Change In Credit Risk Of Liability",
        "terseLabel": "Gains / (losses) from own credit on financial liabilities designated at fair value, before tax",
        "totalLabel": "Total gain / (loss), before tax"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of other comprehensive income, before tax, related to change in the fair value of financial liability attributable to change in the credit risk of the liability. [Refer: Other comprehensive income, before tax; Credit risk [member]]"
       }
      }
     },
     "auth_ref": [
      "r20",
      "r33"
     ]
    },
    "ifrs-full_OtherComprehensiveIncomeBeforeTaxChangeInValueOfForeignCurrencyBasisSpreads": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "OtherComprehensiveIncomeBeforeTaxChangeInValueOfForeignCurrencyBasisSpreads",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome": {
       "parentTag": "ifrs-full_OtherComprehensiveIncomeNetOfTaxChangeInValueOfForeignCurrencyBasisSpreads",
       "weight": 1.0,
       "order": 22.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Comprehensive Income Before Tax Change In Value Of Foreign Currency Basis Spreads",
        "terseLabel": "Cost of hedging, before tax"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of other comprehensive income, before tax, after reclassification adjustments, related to change in value of foreign currency basis spreads. [Refer: Other comprehensive income, before tax]"
       }
      }
     },
     "auth_ref": [
      "r20",
      "r33"
     ]
    },
    "ifrs-full_OtherComprehensiveIncomeBeforeTaxGainsLossesOnRemeasurementsOfDefinedBenefitPlans": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "OtherComprehensiveIncomeBeforeTaxGainsLossesOnRemeasurementsOfDefinedBenefitPlans",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome": {
       "parentTag": "ifrs-full_OtherComprehensiveIncomeNetOfTaxGainsLossesOnRemeasurementsOfDefinedBenefitPlans",
       "weight": 1.0,
       "order": 26.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Comprehensive Income Before Tax Gains Losses On Remeasurements Of Defined Benefit Plans",
        "terseLabel": "Gains / (losses) on defined benefit plans, before tax",
        "positiveTerseLabel": "Amounts recognized in other comprehensive income",
        "totalLabel": "Total gains / (losses) recognized in other comprehensive income, before tax",
        "verboseLabel": "Gains / (losses) recognized in other comprehensive income, before tax"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of other comprehensive income, before tax, related to gains (losses) on remeasurements of defined benefit plans, which comprise actuarial gains and losses; the return on plan assets, excluding amounts included in net interest on the net defined benefit liability (asset); and any change in the effect of the asset ceiling, excluding amounts included in net interest on the net defined benefit liability (asset). [Refer: Other comprehensive income; Defined benefit plans [member]; Plan assets [member]; Net defined benefit liability (asset)] [Contrast: Decrease (increase) in net defined benefit liability (asset) resulting from gain (loss) on remeasurement in other comprehensive income]"
       }
      }
     },
     "auth_ref": [
      "r20",
      "r33",
      "r254"
     ]
    },
    "ubsag_OtherComprehensiveIncomeChangeInFairValueOfFinancialLiabilityAttributableToChangeInCreditRiskOfLiabilityAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherComprehensiveIncomeChangeInFairValueOfFinancialLiabilityAttributableToChangeInCreditRiskOfLiabilityAbstract",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Comprehensive Income Change In Fair Value Of Financial Liability Attributable To Change In Credit Risk Of Liability [Abstract]",
        "terseLabel": "Own credit on financial liabilities designated at fair value"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherComprehensiveIncomeDefinedBenefitPlansAdjustmentnetOfTaxPeriodIncreaseDecreaseAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherComprehensiveIncomeDefinedBenefitPlansAdjustmentnetOfTaxPeriodIncreaseDecreaseAbstract",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Comprehensive Income Defined Benefit Plans Adjustment net Of Tax Period Increase Decrease [Abstract]",
        "terseLabel": "Defined benefit plans"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_OtherComprehensiveIncomeNetOfTaxCashFlowHedges": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "OtherComprehensiveIncomeNetOfTaxCashFlowHedges",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Comprehensive Income Net Of Tax Cash Flow Hedges",
        "totalLabel": "Subtotal cash flow hedges, net of tax",
        "terseLabel": "Cash flow hedges, net of tax"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of other comprehensive income, net of tax, after reclassification adjustments, related to cash flow hedges. [Refer: Cash flow hedges [member]; Other comprehensive income]"
       }
      }
     },
     "auth_ref": [
      "r20",
      "r32"
     ]
    },
    "ifrs-full_OtherComprehensiveIncomeNetOfTaxChangeInFairValueOfFinancialLiabilityAttributableToChangeInCreditRiskOfLiability": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "OtherComprehensiveIncomeNetOfTaxChangeInFairValueOfFinancialLiabilityAttributableToChangeInCreditRiskOfLiability",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Comprehensive Income Net Of Tax Change In Fair Value Of Financial Liability Attributable To ChangeI n Credit Risk Of Liability",
        "totalLabel": "Subtotal own credit on financial liabilities designated at fair value, net of tax",
        "verboseLabel": "Own credit on financial liabilities designated at fair value, net of tax"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of other comprehensive income, net of tax, related to changes in the fair value of financial liabilities attributable to the changes in the credit risk of those liabilities. [Refer: Other comprehensive income; Credit risk [member]; Financial liabilities]"
       }
      }
     },
     "auth_ref": [
      "r20",
      "r32"
     ]
    },
    "ifrs-full_OtherComprehensiveIncomeNetOfTaxChangeInValueOfForeignCurrencyBasisSpreads": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "OtherComprehensiveIncomeNetOfTaxChangeInValueOfForeignCurrencyBasisSpreads",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Comprehensive Income Net Of Tax Change In Value Of Foreign Currency Basis Spreads",
        "totalLabel": "Subtotal cost of hedging, net of tax",
        "verboseLabel": "Other comprehensive income, net of tax, change in value of foreign currency basis spreads",
        "terseLabel": "Cost of hedging, net of tax"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of other comprehensive income, net of tax, after reclassification adjustments, related to change in value of foreign currency basis spreads. [Refer: Other comprehensive income]"
       }
      }
     },
     "auth_ref": [
      "r20",
      "r32"
     ]
    },
    "ifrs-full_OtherComprehensiveIncomeNetOfTaxExchangeDifferencesOnTranslation": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "OtherComprehensiveIncomeNetOfTaxExchangeDifferencesOnTranslation",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Comprehensive Income Net Of Tax Exchange Differences On Translation",
        "terseLabel": "of which: OCI that will not be reclassified to the income statement, net of tax - foreign currency translation",
        "totalLabel": "Subtotal foreign currency translation, net of tax",
        "verboseLabel": "Foreign currency translation, net of tax"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of other comprehensive income, net of tax, after reclassification adjustments, related to exchange differences when financial statements of foreign operations are translated. [Refer: Other comprehensive income]"
       }
      }
     },
     "auth_ref": [
      "r20",
      "r32"
     ]
    },
    "ifrs-full_OtherComprehensiveIncomeNetOfTaxFinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncome": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "OtherComprehensiveIncomeNetOfTaxFinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncome",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Comprehensive Income Net Of Tax Financial Assets Measured At Fair Value Through Other Comprehensive Income",
        "totalLabel": "Subtotal financial assets measured at fair value through other comprehensive income, net of tax",
        "terseLabel": "Financial assets available for sale, net of tax",
        "verboseLabel": "Financial assets measured at fair value through other comprehensive income, net of tax"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of other comprehensive income, net of tax, after reclassification adjustments, related to financial assets measured at fair value through other comprehensive income applying paragraph 4.1.2A of IFRS 9. [Refer: Financial assets measured at fair value through other comprehensive income; Other comprehensive income]"
       }
      }
     },
     "auth_ref": [
      "r20",
      "r32"
     ]
    },
    "ifrs-full_OtherComprehensiveIncomeNetOfTaxGainsLossesOnRemeasurementsOfDefinedBenefitPlans": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "OtherComprehensiveIncomeNetOfTaxGainsLossesOnRemeasurementsOfDefinedBenefitPlans",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Comprehensive Income Net Of Tax Gains Losses On Remeasurements Of Defined Benefit Plans",
        "totalLabel": "Subtotal defined benefit plans, net of tax",
        "positiveTerseLabel": "Defined benefit plans, net of tax"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of other comprehensive income, net of tax, related to gains (losses) on remeasurements of defined benefit plans, which comprise actuarial gains and losses; the return on plan assets, excluding amounts included in net interest on the net defined benefit liability (asset); and any change in the effect of the asset ceiling, excluding amounts included in net interest on the net defined benefit liability (asset). [Refer: Other comprehensive income; Defined benefit plans [member]; Plan assets [member]; Net defined benefit liability (asset)] [Contrast: Decrease (increase) in net defined benefit liability (asset) resulting from gain (loss) on remeasurement in other comprehensive income]"
       }
      }
     },
     "auth_ref": [
      "r20",
      "r32",
      "r254"
     ]
    },
    "ifrs-full_OtherComprehensiveIncomeThatWillBeReclassifiedToProfitOrLossNetOfTax": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "OtherComprehensiveIncomeThatWillBeReclassifiedToProfitOrLossNetOfTax",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome": {
       "parentTag": "ifrs-full_OtherComprehensiveIncome",
       "weight": 1.0,
       "order": 35.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Comprehensive Income That Will Be Reclassified To Profit Or Loss Net Of Tax",
        "terseLabel": "Total other comprehensive income that may be reclassified to the income statement, net of tax"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of other comprehensive income that will be reclassified to profit or loss, net of tax. [Refer: Other comprehensive income]"
       }
      }
     },
     "auth_ref": [
      "r200",
      "r201"
     ]
    },
    "ifrs-full_OtherComprehensiveIncomeThatWillNotBeReclassifiedToProfitOrLossNetOfTax": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "OtherComprehensiveIncomeThatWillNotBeReclassifiedToProfitOrLossNetOfTax",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome": {
       "parentTag": "ifrs-full_OtherComprehensiveIncome",
       "weight": 1.0,
       "order": 36.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Comprehensive Income That Will Not Be Reclassified To Profit Or Loss Net Of Tax",
        "totalLabel": "Total other comprehensive income that will not be reclassified to the income statement, net of tax",
        "terseLabel": "Total other comprehensive income that will not be reclassified to the income statement, net of tax",
        "verboseLabel": "Total other comprehensive income that will not be reclassified to the income statement, net of tax"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of other comprehensive income that will not be reclassified to profit or loss, net of tax. [Refer: Other comprehensive income]"
       }
      }
     },
     "auth_ref": [
      "r200",
      "r201"
     ]
    },
    "ubsag_OtherConsolidatedEntitiesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherConsolidatedEntitiesMember",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Consolidated Entities [Member]",
        "terseLabel": "UBS",
        "documentation": "This member stands for entity or group of entities consolidated into reporting entity, excluding Credit Suisse."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_OtherEmployeeExpense": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "OtherEmployeeExpense",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/PersonnelExpensesDetail": {
       "parentTag": "ifrs-full_EmployeeBenefitsExpense",
       "weight": 1.0,
       "order": 7.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/PersonnelExpensesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Employee Expense",
        "terseLabel": "Other personnel expenses"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of employee expenses that the entity does not separately disclose in the same statement or note."
       }
      }
     },
     "auth_ref": [
      "r255"
     ]
    },
    "ubsag_OtherEntitiesAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherEntitiesAbstract",
     "presentation": [
      "http://www.ubsag.com/role/OtherIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Entities [Abstract]",
        "terseLabel": "Associates, joint ventures and subsidiaries"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_OtherFeeAndCommissionIncome": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "OtherFeeAndCommissionIncome",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail": {
       "parentTag": "ifrs-full_FeeAndCommissionIncome",
       "weight": 1.0,
       "order": 7.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Fee And Commission Income",
        "terseLabel": "Other"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of fee and commission income that the entity does not separately disclose in the same statement or note. [Refer: Fee and commission income]"
       }
      }
     },
     "auth_ref": [
      "r247"
     ]
    },
    "ubsag_OtherFinancialAssetsAtAmortisedCost": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherFinancialAssetsAtAmortisedCost",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_FinancialAssetsAtAmortisedCost",
       "weight": 1.0,
       "order": 8.0
      },
      "http://www.ubsag.com/role/OtherFinancialAssetsMeasuredAtAmortizedCostDetail": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/FVMFinancialInstrumentsNotMeasuredAtFairValueAssetsDetail",
      "http://www.ubsag.com/role/OtherFinancialAssetsMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "terseLabel": "Other financial assets measured at amortized cost",
        "totalLabel": "Total other financial assets measured at amortized cost",
        "label": "Other Financial Assets At Amortised Cost",
        "documentation": "The amount of other financial assets that are held at amortized cost."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherFinancialAssetsAtAmortisedCostMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherFinancialAssetsAtAmortisedCostMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Financial Assets At Amortised Cost [Member]",
        "terseLabel": "Other financial assets measured at amortized cost",
        "documentation": "This member stands for the other financial assets measured at amortized cost."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherFinancialAssetsAtAmortisedCostMiscellaneous": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherFinancialAssetsAtAmortisedCostMiscellaneous",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/OtherFinancialAssetsMeasuredAtAmortizedCostDetail": {
       "parentTag": "ubsag_OtherFinancialAssetsAtAmortisedCost",
       "weight": 1.0,
       "order": 8.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherFinancialAssetsMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Financial Assets At Amortised Cost Miscellaneous",
        "terseLabel": "Other",
        "documentation": "The amount of other miscellaneous financial assets that are held at amortized cost."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherFinancialAssetsAtAmortisedCostTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherFinancialAssetsAtAmortisedCostTransferredAsOfTheMergerDate",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Financial Assets At Amortised Cost Transferred As Of The Merger Date",
        "terseLabel": "Other financial assets measured at amortized cost",
        "documentation": "The amount of other financial assets that are held at amortized cost."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherFinancialInstrumentsNetMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherFinancialInstrumentsNetMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsSensitivityToChangesInUnobservableInputAssumptionsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Financial Instruments Net [Member]",
        "terseLabel": "Other",
        "documentation": "This member relates to other financial instruments."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherFinancialLiabilitiesAtAmortisedCost": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherFinancialLiabilitiesAtAmortisedCost",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_FinancialLiabilitiesAtAmortisedCost",
       "weight": 1.0,
       "order": 30.0
      },
      "http://www.ubsag.com/role/OtherFinancialLiabilitiesMeasuredAtAmortizedCostDetail": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/OtherFinancialLiabilitiesMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Financial Liabilities At Amortised Cost",
        "terseLabel": "Other financial liabilities measured at amortized cost",
        "documentation": "The amount of other financial liabilities that are held at amortized cost.",
        "totalLabel": "Total other financial liabilities measured at amortized cost"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherFinancialLiabilitiesAtAmortisedCostExcludingLeaseLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherFinancialLiabilitiesAtAmortisedCostExcludingLeaseLiabilities",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/FVMFinancialInstrumentsNotMeasuredAtFairValueLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Financial Liabilities At Amortised Cost Excluding Lease Liabilities",
        "terseLabel": "Other financial liabilities measured at amortized cost excluding lease liabilities",
        "documentation": "The amount of other financial liabilities that are held at amortized cost excluding lease liabilities."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherFinancialLiabilitiesAtAmortisedCostMiscellaneous": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherFinancialLiabilitiesAtAmortisedCostMiscellaneous",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/OtherFinancialLiabilitiesMeasuredAtAmortizedCostDetail": {
       "parentTag": "ubsag_OtherFinancialLiabilitiesAtAmortisedCost",
       "weight": 1.0,
       "order": 6.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherFinancialLiabilitiesMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Financial Liabilities At Amortised Cost Miscellaneous",
        "terseLabel": "Other",
        "documentation": "The amount of other miscellaneous financial liabilities that are held at amortized cost."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherFinancialLiabilitiesAtAmortisedCostTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherFinancialLiabilitiesAtAmortisedCostTransferredAsOfTheMergerDate",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Financial Liabilities At Amortised Cost Transferred As Of The Merger Date",
        "terseLabel": "Other financial liabilities measured at amortized cost",
        "documentation": "The amount of other financial liabilities that are held at amortized cost."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherFinancialLiabilitiesAtFairValueThroughProfitOrLossDesignatedAsUponInitialRecognition": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherFinancialLiabilitiesAtFairValueThroughProfitOrLossDesignatedAsUponInitialRecognition",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail": {
       "parentTag": "ifrs-full_FinancialLiabilitiesAtFairValueThroughProfitOrLoss",
       "weight": 1.0,
       "order": 6.0
      },
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_FinancialLiabilitiesAtFairValueThroughProfitOrLoss",
       "weight": 1.0,
       "order": 36.0
      },
      "http://www.ubsag.com/role/OtherFinancialLiabilitiesDesignatedAtFairValueDetail": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail",
      "http://www.ubsag.com/role/OtherFinancialLiabilitiesDesignatedAtFairValueDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Financial Liabilities At Fair Value Through Profit Or Loss Designated As Upon Initial Recognition",
        "terseLabel": "Other financial liabilities designated at fair value",
        "documentation": "The amount of other financial liabilities designated at fair value.",
        "totalLabel": "Total other financial liabilities designated at fair value"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherFinancialLiabilitiesAtFairValueThroughProfitOrLossDesignatedAsUponInitialRecognitionMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherFinancialLiabilitiesAtFairValueThroughProfitOrLossDesignatedAsUponInitialRecognitionMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Financial Liabilities At Fair Value Through Profit Or Loss Designated As Upon Initial Recognition [Member]",
        "terseLabel": "Other financial liabilities designated at fair value",
        "documentation": "This member stands for the other financial liabilities designated at fair value."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherFinancialLiabilitiesAtFairValueThroughProfitOrLossDesignatedAsUponInitialRecognitionTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherFinancialLiabilitiesAtFairValueThroughProfitOrLossDesignatedAsUponInitialRecognitionTransferredAsOfTheMergerDate",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Financial Liabilities At Fair Value Through Profit Or Loss Designated As Upon Initial Recognition Transferred As Of The Merger Date",
        "terseLabel": "Other financial liabilities designated at fair value",
        "documentation": "The amount of other financial liabilities designated at fair value."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherFinancialLiabilitiesAtFairValueThroughProfitOrLossOverTheCounterDebtInstrumentsAndMiscellaneous": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherFinancialLiabilitiesAtFairValueThroughProfitOrLossOverTheCounterDebtInstrumentsAndMiscellaneous",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/OtherFinancialLiabilitiesDesignatedAtFairValueDetail": {
       "parentTag": "ubsag_OtherFinancialLiabilitiesAtFairValueThroughProfitOrLossDesignatedAsUponInitialRecognition",
       "weight": 1.0,
       "order": 4.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherFinancialLiabilitiesDesignatedAtFairValueDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Financial Liabilities At Fair Value Through Profit Or Loss Over The Counter Debt Instruments And Miscellaneous",
        "terseLabel": "Over-the-counter debt instruments and other",
        "documentation": "The amount of over-the-counter debt instruments and other miscellaneous financial liabilities that are designated at fair value."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_OtherIncome": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "OtherIncome",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement": {
       "parentTag": "ifrs-full_RevenueAndOperatingIncome",
       "weight": 1.0,
       "order": 10.0
      },
      "http://www.ubsag.com/role/OtherIncomeDetail": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement",
      "http://www.ubsag.com/role/OtherIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Income",
        "terseLabel": "Other income",
        "totalLabel": "Total other income"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of operating income that the entity does not separately disclose in the same statement or note."
       }
      }
     },
     "auth_ref": [
      "r49",
      "r195",
      "r196"
     ]
    },
    "ifrs-full_OtherIncomeExpenseFromSubsidiariesJointlyControlledEntitiesAndAssociates": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "OtherIncomeExpenseFromSubsidiariesJointlyControlledEntitiesAndAssociates",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/OtherIncomeDetail": {
       "parentTag": "ifrs-full_OtherIncome",
       "weight": 1.0,
       "order": 5.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Income Expense From Subsidiaries Jointly Controlled Entities And Associates",
        "totalLabel": "Total"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of income or expense from subsidiaries, jointly controlled entities and associates that the entity does not separately disclose in the same statement or note. [Refer: Associates [member]; Subsidiaries [member]]"
       }
      }
     },
     "auth_ref": [
      "r252"
     ]
    },
    "ubsag_OtherIncomeFromSharedServices": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherIncomeFromSharedServices",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/OtherIncomeDetail": {
       "parentTag": "ifrs-full_OtherIncome",
       "weight": 1.0,
       "order": 7.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Income From Shared Services",
        "terseLabel": "Income from shared services provided to UBS Group AG or its subsidiaries",
        "documentation": "The amount of income from shared services provided to the parent company or its group of subsidiaries."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherIncomeLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherIncomeLineItems",
     "presentation": [
      "http://www.ubsag.com/role/OtherIncome",
      "http://www.ubsag.com/role/OtherIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Income [Line Items]",
        "terseLabel": "Other income",
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with domain members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherIncomeOther": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherIncomeOther",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/OtherIncomeDetail": {
       "parentTag": "ifrs-full_OtherIncome",
       "weight": 1.0,
       "order": 8.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Income Other",
        "terseLabel": "Other",
        "documentation": "The amount of other miscellaneous income.",
        "verboseLabel": "Other income other"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherIncomeTable": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherIncomeTable",
     "presentation": [
      "http://www.ubsag.com/role/OtherIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Income [Table]",
        "documentation": "Schedule disclosing information related to other income."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherIncomeTablesLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherIncomeTablesLineItems",
     "presentation": [
      "http://www.ubsag.com/role/OtherIncomeTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Income Tables [Line Items]",
        "terseLabel": "Other income",
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with domain members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_OtherInflowsOutflowsOfCashClassifiedAsFinancingActivities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "OtherInflowsOutflowsOfCashClassifiedAsFinancingActivities",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInFinancingActivities",
       "weight": 1.0,
       "order": 43.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Inflows Outflows Of Cash Classified As Financing Activities",
        "terseLabel": "Net cash flows from other financing activities"
       }
      },
      "en": {
       "role": {
        "documentation": "Inflows (outflows) of cash, classified as financing activities, that the entity does not separately disclose in the same statement or note."
       }
      }
     },
     "auth_ref": [
      "r74"
     ]
    },
    "ubsag_OtherIntragroupFundingAtAmortisedCost": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherIntragroupFundingAtAmortisedCost",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/FundingFromGroupMeasuredAtAmortizedCostDetail": {
       "parentTag": "ubsag_IntragroupFundingAtAmortisedCost",
       "weight": 1.0,
       "order": 5.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/FundingFromGroupMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Intragroup Funding At Amortised Cost",
        "terseLabel": "Other",
        "documentation": "The amount of other intra-group funding measured at amortized cost."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherIssuedDebtInstrumentsDesignatedAtFairValueThroughProfitOrLoss": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherIssuedDebtInstrumentsDesignatedAtFairValueThroughProfitOrLoss",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueDetail": {
       "parentTag": "ubsag_DebtSecuritiesIssuedAtFairValueThroughProfitOrLossDesignatedAsUponInitialRecognition",
       "weight": 1.0,
       "order": 8.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Issued Debt Instruments Designated At Fair Value Through Profit Or Loss",
        "terseLabel": "Other",
        "documentation": "The amount of other miscellaneous debt instruments that have been issued and are designated at fair value."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherLendingMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherLendingMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Lending [Member]",
        "terseLabel": "Total other lending",
        "documentation": "This member relates to a class of financial assets that represents total other lending."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherLoansAndAdvancesToCustomersMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherLoansAndAdvancesToCustomersMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Loans And Advances To Customers [Member]",
        "terseLabel": "Other loans and advances to customers",
        "documentation": "This member relates to other loans and advances the entity has made to customers."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherLongTermDebtIssued": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherLongTermDebtIssued",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostDetail": {
       "parentTag": "ifrs-full_NoncurrentDebtInstrumentsIssued",
       "weight": 1.0,
       "order": 10.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The amount of other miscellaneous long-term debt issued by the entiy",
        "terseLabel": "Other long-term debt",
        "label": "Other Long Term Debt Issued"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherLongTermDebtIssuedSecuredPortion": {
     "xbrltype": "percentItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherLongTermDebtIssuedSecuredPortion",
     "presentation": [
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Long Term Debt Issued Secured Portion",
        "documentation": "The percentage for secured portion of Other long-term debt.",
        "terseLabel": "Secured portion of Other long-term debt"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other [Member]",
        "terseLabel": "Other",
        "documentation": "This member relates to other financial instruments."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherNetIncomeFromFinancialInstrumentsMeasuredAtFairValueThroughProfitOrLoss": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherNetIncomeFromFinancialInstrumentsMeasuredAtFairValueThroughProfitOrLoss",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement": {
       "parentTag": "ifrs-full_RevenueAndOperatingIncome",
       "weight": 1.0,
       "order": 6.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Net Income From Financial Instruments Measured At Fair Value Through Profit Or Loss",
        "terseLabel": "Other net income from financial instruments measured at fair value through profit or loss",
        "documentation": "The amount of other net income from financial instruments measured at fair value through profit or loss."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherNetIncomeFromProperties": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherNetIncomeFromProperties",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/OtherIncomeDetail": {
       "parentTag": "ifrs-full_OtherIncome",
       "weight": 1.0,
       "order": 6.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Net Income From Properties",
        "terseLabel": "Income from properties",
        "documentation": "The amount of net income generated from properties."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherNonFinancialAssetsLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherNonFinancialAssetsLineItems",
     "presentation": [
      "http://www.ubsag.com/role/OtherNonfinancialAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Non-Financial Assets [Line Items]",
        "terseLabel": "Other assets",
        "documentation": "disclose reportable information associated with domain members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherNonFinancialAssetsMiscellaneous": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherNonFinancialAssetsMiscellaneous",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/OtherNonfinancialAssetsDetail": {
       "parentTag": "ifrs-full_OtherNonfinancialAssets",
       "weight": 1.0,
       "order": 8.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherNonfinancialAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Non Financial Assets Miscellaneous",
        "terseLabel": "Other",
        "documentation": "The amount of other miscellaneous non-financial assets."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherNonFinancialLiabilitiesLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherNonFinancialLiabilitiesLineItems",
     "presentation": [
      "http://www.ubsag.com/role/OtherNonfinancialLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Non-Financial Liabilities [Line Items]",
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with domain members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherNonFinancialLiabilitiesMiscellaneous": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherNonFinancialLiabilitiesMiscellaneous",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/OtherNonfinancialLiabilitiesDetail": {
       "parentTag": "ifrs-full_OtherNonfinancialLiabilities",
       "weight": 1.0,
       "order": 12.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherNonfinancialLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Non Financial Liabilities Miscellaneous",
        "terseLabel": "Other",
        "documentation": "The amount of other miscellaneous non-financial liabilities."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_OtherNonfinancialAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "OtherNonfinancialAssets",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_Assets",
       "weight": 1.0,
       "order": 21.0
      },
      "http://www.ubsag.com/role/OtherNonfinancialAssetsDetail": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/OtherNonfinancialAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other non-financial assets",
        "terseLabel": "Other non-financial assets",
        "totalLabel": "Total other non-financial assets"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of non-financial assets that the entity does not separately disclose in the same statement or note. [Refer: Financial assets]"
       }
      }
     },
     "auth_ref": [
      "r249"
     ]
    },
    "ubsag_OtherNonfinancialAssetsAtFairValue": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherNonfinancialAssetsAtFairValue",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail": {
       "parentTag": "ubsag_AssetsMeasuredAtFairValue",
       "weight": 1.0,
       "order": 8.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other non-financial assets, at fair value",
        "terseLabel": "Other non-financial assets",
        "totalLabel": "Total other non-financial assets",
        "documentation": "The fair value amount of other non-financial assets.",
        "verboseLabel": "Other non-financial assets measured at fair value"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherNonfinancialAssetsTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherNonfinancialAssetsTransferredAsOfTheMergerDate",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Nonfinancial Assets Transferred As Of The Merger Date",
        "terseLabel": "Other non-financial assets",
        "documentation": "The amount of non-financial assets that the entity does not separately disclose in the same statement or note. [Refer: Financial assets]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_OtherNonfinancialLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "OtherNonfinancialLiabilities",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_Liabilities",
       "weight": 1.0,
       "order": 39.0
      },
      "http://www.ubsag.com/role/OtherNonfinancialLiabilitiesDetail": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/OtherNonfinancialLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Non-financial Liabilities",
        "terseLabel": "Other non-financial liabilities",
        "totalLabel": "Total other non-financial liabilities"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of non-financial liabilities that the entity does not separately disclose in the same statement or note. [Refer: Other financial liabilities]"
       }
      }
     },
     "auth_ref": [
      "r249"
     ]
    },
    "ubsag_OtherNonfinancialLiabilitiesTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherNonfinancialLiabilitiesTransferredAsOfTheMergerDate",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Nonfinancial Liabilities Transferred As Of The Merger Date",
        "terseLabel": "Other non-financial liabilities",
        "documentation": "The amount of non-financial liabilities that the entity does not separately disclose in the same statement or note. [Refer: Other financial liabilities]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherOffbalanceSheetCommitmentsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherOffbalanceSheetCommitmentsMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Off-balance Sheet Commitments [Member]",
        "terseLabel": "Other off-balance sheet commitments",
        "documentation": "This member relates to other off-balance sheet commitments."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_OtherProvisionsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "OtherProvisionsMember",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersDetail",
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail",
      "http://www.ubsag.com/role/ProvisionsAdditionalInformationDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Provisions [Member]",
        "terseLabel": "Provisions"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for provisions other than provisions for employee benefits. It also represents the standard value for the 'Classes of other provisions' axis if no other member is used. [Refer: Provisions]"
       }
      }
     },
     "auth_ref": [
      "r59"
     ]
    },
    "ifrs-full_OtherReservesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "OtherReservesMember",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity",
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquityParenthetical"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Reserves [Member]",
        "terseLabel": "Other comprehensive income recognized directly in equity, net of tax"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a component of equity representing reserves within equity, not including retained earnings. It also represents the standard value for the 'Reserves within equity' axis if no other member is used. [Refer: Retained earnings]"
       }
      }
     },
     "auth_ref": [
      "r6",
      "r22"
     ]
    },
    "ubsag_OtherRiskMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherRiskMember",
     "presentation": [
      "http://www.ubsag.com/role/DerivativeInstrumentsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Risk [Member]",
        "terseLabel": "Other",
        "documentation": "This member relates to loan commitments measured at FVTPL and unsettled purchases and sales of non-derivative financial instruments."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OtherValuationAdjustments": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OtherValuationAdjustments",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/FVMValuationAdjustmentsReservesOnTheBalanceSheetDetail": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/FVMValuationAdjustmentsReservesOnTheBalanceSheetDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Other Valuation Adjustments",
        "totalLabel": "Other valuation adjustments",
        "documentation": "The amount of other valuation adjustments made on financial instruments."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OutflowsOfCashFromSecuritiesFinancingTransactionsMeasuredAtAmortizedCost": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OutflowsOfCashFromSecuritiesFinancingTransactionsMeasuredAtAmortizedCost",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInFinancingActivities",
       "weight": -1.0,
       "order": 42.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Outflows Of Cash From Securities Financing Transactions Measured At Amortized Cost",
        "negatedLabel": "Outflows from securities financing transactions measured at amortized cost",
        "documentation": "Reflects cash outflows from securities financing transactions measured at amortized cost that use entity's debt instruments as the underlying."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OutsourcingExpense": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OutsourcingExpense",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesDetail": {
       "parentTag": "ifrs-full_GeneralAndAdministrativeExpense",
       "weight": 1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Outsourcing Expense",
        "terseLabel": "Outsourcing costs",
        "documentation": "The amount of expense incurred in the period for outsourcing of IT and other services."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_OverTheCounterDebtInstrumentsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "OverTheCounterDebtInstrumentsMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Over The Counter Debt Instruments [Member]",
        "terseLabel": "Over-the-counter debt instruments",
        "documentation": "This member relates to over-the-counter debt instruments."
       }
      }
     },
     "auth_ref": []
    },
    "srt_ParentCompanyMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://fasb.org/srt/2023",
     "localname": "ParentCompanyMember",
     "presentation": [
      "http://www.ubsag.com/role/SupplementalGuarantorConsolidatedStatementOfCashFlowsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Parent Company [Member]",
        "terseLabel": "UBS AG (standalone)"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_PayablesFromTaxesOtherThanIncomeTax": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "PayablesFromTaxesOtherThanIncomeTax",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/OtherNonfinancialLiabilitiesDetail": {
       "parentTag": "ifrs-full_OtherNonfinancialLiabilities",
       "weight": 1.0,
       "order": 10.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherNonfinancialLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Payables From Taxes Other Than Income Tax",
        "terseLabel": "VAT, withholding tax and other tax payables",
        "documentation": "The amount of value-added taxes and other tax payables for current and prior periods to the extent unpaid."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_PensionAndOtherPostemploymentBenefitPlansCurtailments": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "PensionAndOtherPostemploymentBenefitPlansCurtailments",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/PersonnelExpensesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Pension And Other Postemployment Benefit Plans Curtailments",
        "terseLabel": "Curtailments",
        "documentation": "The amount of gains resulting from a reduction in pension and other post-employment benefit obligation following a reduction in the number of employees covered due to restructuring."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_PercentageOfTenderedAndAcceptedFundUnits": {
     "xbrltype": "percentItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "PercentageOfTenderedAndAcceptedFundUnits",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Percentage Of Tendered And Accepted Fund Units",
        "terseLabel": "Percentage of tendered and accepted fund units",
        "documentation": "The amount of tendered and accepted fund units, in percentage."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_PersonnelExpensesLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "PersonnelExpensesLineItems",
     "presentation": [
      "http://www.ubsag.com/role/PersonnelExpenses",
      "http://www.ubsag.com/role/PersonnelExpensesDetail",
      "http://www.ubsag.com/role/PersonnelExpensesTables"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Personnel Expenses [Line Items]",
        "terseLabel": "Personnel expenses",
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with domain members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_PersonnelRelatedRestructuringProvision": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "PersonnelRelatedRestructuringProvision",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/ProvisionsAdditionalInformationDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Personnel Related Restructuring Provision",
        "terseLabel": "Personnel-related restructuring provisions",
        "documentation": "The amount of personnel-related provision for restructuring, such as the sale or termination of a line of business; closure of business locations in a country or region or relocation of activities from one country or region to another; changes in management structure; and fundamental reorganisations that have a material effect on the nature and focus of the entity's operations. [Refer: Other provisions]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_PortfolioAndOtherManagementFeeIncome": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "PortfolioAndOtherManagementFeeIncome",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail": {
       "parentTag": "ifrs-full_FeeAndCommissionIncome",
       "weight": 1.0,
       "order": 6.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Portfolio And Other Management Fee Income",
        "terseLabel": "Portfolio management and related services"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of income recognised from portfolio and other management fees."
       }
      }
     },
     "auth_ref": [
      "r247"
     ]
    },
    "ubsag_PostModelCreditLossExpenseAdjustmentMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "PostModelCreditLossExpenseAdjustmentMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementChangesToECLModelsScenariosScenarioWeightsAndPostmodelAdjustmentsNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Post-model Credit Loss Expense Adjustment [Member]",
        "terseLabel": "Post-model adjustment",
        "documentation": "This member stands for post-model credit loss expense adjustment."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_PostemploymentBenefitPlansExpense": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "PostemploymentBenefitPlansExpense",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/PersonnelExpensesDetail": {
       "parentTag": "ifrs-full_EmployeeBenefitsExpense",
       "weight": 1.0,
       "order": 6.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/PersonnelExpensesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Post-employment Benefit Plans Expense",
        "terseLabel": "Post-employment benefit plans",
        "documentation": "The amount of post-employment benefit expense relating to various types of defined benefit plans and other defined contribution plans.",
        "totalLabel": "Total post-employment benefit plan expenses"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_PotentialGainsLossesOnFinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncomeIfNotReclassified": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "PotentialGainsLossesOnFinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncomeIfNotReclassified",
     "presentation": [
      "http://www.ubsag.com/role/ReclassificationOfFinancialAssetsNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Potential Gains Losses On Financial Assets Measured At Fair Value Through Other Comprehensive Income If Not Reclassified",
        "terseLabel": "Potential gains (losses) before tax on reclassified financial assets measured at fair value through other comprehensive income, if not reclassified",
        "documentation": "The amount of potential gains (losses) before tax on reclassified financial assets measured at fair value through other comprehensive income, if not reclassified."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_PreciousMetalsAndOtherPhysicalCommodities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "PreciousMetalsAndOtherPhysicalCommodities",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/OtherNonfinancialAssetsDetail": {
       "parentTag": "ifrs-full_OtherNonfinancialAssets",
       "weight": 1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherNonfinancialAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Precious metals and other physical commodities",
        "documentation": "The amount of precious metals and other physical commodities."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_PreciousMetalsAndOtherPhysicalCommoditiesMeasuredAtFairValue": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "PreciousMetalsAndOtherPhysicalCommoditiesMeasuredAtFairValue",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail": {
       "parentTag": "ubsag_AssetsMeasuredAtFairValue",
       "weight": 1.0,
       "order": 7.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Precious Metals And Other Physical Commodities Measured At Fair Value",
        "terseLabel": "Non-financial assets - Precious metals and other physical commodities",
        "documentation": "The fair value amount of precious metals and other physical commodities."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_PremiumOnSharesIssuedAndWarrantsExercised": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "PremiumOnSharesIssuedAndWarrantsExercised",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Premium On Shares Issued And Warrants Exercised",
        "terseLabel": "Premium on shares issued and warrants exercised",
        "documentation": "The increase in equity resulting from the premium on shares issued and warrants exercised."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_Prepayments": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "Prepayments",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/OtherNonfinancialAssetsDetail": {
       "parentTag": "ifrs-full_OtherNonfinancialAssets",
       "weight": 1.0,
       "order": 4.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherNonfinancialAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Prepayments",
        "terseLabel": "Prepaid expenses"
       }
      },
      "en": {
       "role": {
        "documentation": "Receivables that represent amounts paid for goods and services before they have been delivered."
       }
      }
     },
     "auth_ref": [
      "r198"
     ]
    },
    "ifrs-full_ProceedsFromIssueOfBondsNotesAndDebentures": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ProceedsFromIssueOfBondsNotesAndDebentures",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInFinancingActivities",
       "weight": 1.0,
       "order": 39.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Proceeds From Issue Of Bonds Notes And Debentures",
        "terseLabel": "Issuance of debt designated at fair value and long-term debt measured at amortized cost"
       }
      },
      "en": {
       "role": {
        "documentation": "The cash inflow from the issuing of bonds, notes and debentures."
       }
      }
     },
     "auth_ref": [
      "r257"
     ]
    },
    "ubsag_ProceedsFromSaleOfSubsidiariesAssociatesAndIntangibleAssetsClassifiedAsInvestingActivities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ProceedsFromSaleOfSubsidiariesAssociatesAndIntangibleAssetsClassifiedAsInvestingActivities",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInInvestingActivities",
       "weight": 1.0,
       "order": 28.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Proceeds From Sale Of Subsidiaries Associates And Intangible Assets Classified As Investing Activities",
        "terseLabel": "Disposal of subsidiaries, associates and intangible assets",
        "documentation": "The aggregate cash flows arising from losing control of subsidiaries, associates and/or intangible assets, classified as investing activities."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_ProceedsFromSalesOfPropertyEquipmentSoftwareClassifiedAsInvestingActivities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ProceedsFromSalesOfPropertyEquipmentSoftwareClassifiedAsInvestingActivities",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInInvestingActivities",
       "weight": 1.0,
       "order": 30.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Proceeds From Sales Of Property Equipment Software Classified As Investing Activities",
        "terseLabel": "Disposal of property, equipment and software",
        "documentation": "The cash inflow from sales of property, equipment and software, classified as investing activities."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ProfessionalFeesExpense": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ProfessionalFeesExpense",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesDetail": {
       "parentTag": "ifrs-full_GeneralAndAdministrativeExpense",
       "weight": 1.0,
       "order": 4.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Professional Fees Expense",
        "terseLabel": "Consulting, legal and audit fees"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of fees paid or payable for professional services."
       }
      }
     },
     "auth_ref": [
      "r247"
     ]
    },
    "ifrs-full_ProfitLoss": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ProfitLoss",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome": {
       "parentTag": "ifrs-full_ComprehensiveIncome",
       "weight": 1.0,
       "order": 2.0
      },
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInOperatingActivities",
       "weight": 1.0,
       "order": 3.0
      },
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity": {
       "parentTag": "ifrs-full_ComprehensiveIncome",
       "weight": 1.0,
       "order": 19.0
      },
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement",
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows",
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity",
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome",
      "http://www.ubsag.com/role/SegmentReportingDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "terseLabel": "Net profit / (loss)",
        "label": "Profit Loss",
        "totalLabel": "Net profit / (loss)",
        "verboseLabel": "of which: net profit / (loss)"
       }
      },
      "en": {
       "role": {
        "documentation": "The total of income less expenses from continuing and discontinued operations, excluding the components of other comprehensive income. [Refer: Other comprehensive income]"
       }
      }
     },
     "auth_ref": [
      "r2",
      "r23",
      "r72",
      "r85",
      "r87",
      "r176",
      "r179",
      "r208",
      "r221"
     ]
    },
    "ifrs-full_ProfitLossAttributableToNoncontrollingInterests": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ProfitLossAttributableToNoncontrollingInterests",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Profit Loss Attributable To Noncontrolling Interests",
        "terseLabel": "Net profit / (loss) attributable to non-controlling interests"
       }
      },
      "en": {
       "role": {
        "documentation": "The profit (loss) from continuing and discontinued operations attributable to non-controlling interests. [Refer: Profit (loss); Non-controlling interests]"
       }
      }
     },
     "auth_ref": [
      "r26",
      "r89"
     ]
    },
    "ifrs-full_ProfitLossAttributableToOrdinaryEquityHoldersOfParentEntity": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ProfitLossAttributableToOrdinaryEquityHoldersOfParentEntity",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Profit Loss Attributable To Ordinary Equity Holders Of Parent Entity",
        "terseLabel": "Net profit / (loss) attributable to shareholders"
       }
      },
      "en": {
       "role": {
        "documentation": "The profit (loss) attributable to ordinary equity holders of the parent entity. [Refer: Profit (loss)]"
       }
      }
     },
     "auth_ref": [
      "r54"
     ]
    },
    "ifrs-full_ProfitLossBeforeTax": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ProfitLossBeforeTax",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement": {
       "parentTag": "ifrs-full_ProfitLoss",
       "weight": 1.0,
       "order": 17.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement",
      "http://www.ubsag.com/role/SegmentReportingDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Profit Loss Before Tax",
        "totalLabel": "Operating profit / (loss) before tax",
        "terseLabel": "Operating profit / (loss) before tax",
        "verboseLabel": "Pre-tax gain resulted from changes to the Pension Fund of UBS in Switzerland"
       }
      },
      "en": {
       "role": {
        "documentation": "The profit (loss) before tax expense or income. [Refer: Profit (loss)]"
       }
      }
     },
     "auth_ref": [
      "r130",
      "r195",
      "r196",
      "r242",
      "r243"
     ]
    },
    "ubsag_PropertiesAndOtherNoncurrentAssetsClassifiedAsHeldForSale": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "PropertiesAndOtherNoncurrentAssetsClassifiedAsHeldForSale",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/OtherNonfinancialAssetsDetail": {
       "parentTag": "ifrs-full_OtherNonfinancialAssets",
       "weight": 1.0,
       "order": 7.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherNonfinancialAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Properties And Other Noncurrent Assets Classified As Held For Sale",
        "terseLabel": "Properties and other non-current assets held for sale",
        "documentation": "The amount of properties and other non-current assets classified as held for sale."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_PropertyEquipmentSoftware": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "PropertyEquipmentSoftware",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_Assets",
       "weight": 1.0,
       "order": 18.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Property Equipment Software",
        "terseLabel": "Property, equipment and software",
        "documentation": "The amount of software-type of intangible asset, and tangible assets that: (a) are held for use in the production or supply of goods or services, for rental to others, or for administrative purposes; and (b) are expected to be used during more than one period.",
        "periodStartLabel": "Balance at the beginning of the year",
        "periodEndLabel": "Balance at the end of the year"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_PropertyEquipmentSoftwareTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "PropertyEquipmentSoftwareTransferredAsOfTheMergerDate",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Property Equipment Software Transferred As Of The Merger Date",
        "terseLabel": "Property, equipment and software",
        "documentation": "The amount of software-type of intangible asset, and tangible assets that: (a) are held for use in the production or supply of goods or services, for rental to others, or for administrative purposes; and (b) are expected to be used during more than one period."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ProvisionUsedOtherProvisions": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ProvisionUsedOtherProvisions",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersDetail",
      "http://www.ubsag.com/role/ProvisionsAdditionalInformationDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Provisions used in conformity with designated purpose",
        "label": "Provision Used Other Provisions"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount used (ie incurred and charged against the provision) for other provisions. [Refer: Other provisions]"
       }
      }
     },
     "auth_ref": [
      "r57"
     ]
    },
    "ifrs-full_Provisions": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "Provisions",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_Liabilities",
       "weight": 1.0,
       "order": 38.0
      },
      "http://www.ubsag.com/role/ProvisionsDetail": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/ProvisionsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Provisions",
        "terseLabel": "Provisions",
        "totalLabel": "Total provisions"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of liabilities of uncertain timing or amount, including provisions for employee benefits."
       }
      }
     },
     "auth_ref": [
      "r11"
     ]
    },
    "ubsag_ProvisionsForExpectedCreditLossesOnLoanCommitmentsAndFinancialGuaranteeContracts": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ProvisionsForExpectedCreditLossesOnLoanCommitmentsAndFinancialGuaranteeContracts",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ProvisionsDetail": {
       "parentTag": "ifrs-full_Provisions",
       "weight": 1.0,
       "order": 3.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail",
      "http://www.ubsag.com/role/ProvisionsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Provisions For Expected Credit Losses On Loan Commitments And Financial Guarantee Contracts",
        "terseLabel": "Provisions for expected credit losses",
        "documentation": "The amount of the provisions for expected credit losses on loan commitments and financial guarantee contracts.",
        "negatedLabel": "Total ECL provisions"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_ProvisionsOtherThanProvisionsForExpectedCreditLosses": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ProvisionsOtherThanProvisionsForExpectedCreditLosses",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ProvisionsDetail": {
       "parentTag": "ifrs-full_Provisions",
       "weight": 1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersDetail",
      "http://www.ubsag.com/role/ProvisionsAdditionalInformationDetail",
      "http://www.ubsag.com/role/ProvisionsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "periodStartLabel": "Balance as of 31 March 2024",
        "label": "Provisions Other Than Provisions For Expected Credit Losses",
        "periodEndLabel": "Balance as of 30 June 2024",
        "terseLabel": "Provisions other than provisions for expected credit losses",
        "verboseLabel": "Balance",
        "documentation": "The amount of provisions other than provisions for expected credit losses.",
        "positiveTerseLabel": "Balance as of 31 December 2023"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_ProvisionsRecognisedUponMerger": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ProvisionsRecognisedUponMerger",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersDetail",
      "http://www.ubsag.com/role/ProvisionsAdditionalInformationDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Provisions Recognised Upon Merger",
        "documentation": "The amount of provisions recognised upon the merger of UBS AG and Credit Suisse AG.",
        "terseLabel": "Provisions recognized upon merger of UBS AG and Credit Suisse AG"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_ProvisionsTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ProvisionsTransferredAsOfTheMergerDate",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Provisions Transferred As Of The Merger Date",
        "terseLabel": "Provisions and contingent liabilities",
        "documentation": "The amount of liabilities of uncertain timing or amount, including provisions for employee benefits."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_PuchaseOfPropertyEquipmentSoftwareClassifiedAsInvestingActivities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "PuchaseOfPropertyEquipmentSoftwareClassifiedAsInvestingActivities",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInInvestingActivities",
       "weight": -1.0,
       "order": 29.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Puchase Of Property Equipment Software Classified As Investing Activities",
        "negatedLabel": "Purchase of property, equipment and software",
        "documentation": "The cash outflow for the purchases of property, equipment and software, classified as investing activities.",
        "terseLabel": "Purchase of property, equipment and software"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_PuertoRicoSystemBondsIssuedAndUnderwritten": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "PuertoRicoSystemBondsIssuedAndUnderwritten",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Puerto Rico System Bonds Issued And Underwritten",
        "terseLabel": "Amount of bonds issued and underwritten by the System",
        "documentation": "The amount of bonds issued and underwritten by the System, in relation to which plaintiffs alleged violation of purported fiduciary duties and contractual obligations by defendants."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_PurchaseOfDebtSecuritiesMeasuredAtAmortizedCost": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "PurchaseOfDebtSecuritiesMeasuredAtAmortizedCost",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInInvestingActivities",
       "weight": -1.0,
       "order": 32.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Purchase Of Debt Securities Measured At Amortized Cost",
        "documentation": "The cash outflow for the purchase of debt securities measured at amortized cost.",
        "negatedLabel": "Purchase of debt securities measured at amortized cost"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_PurchaseOfSubsidiariesAssociatesAndIntangibleAssetsClassifiedAsInvestingActivities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "PurchaseOfSubsidiariesAssociatesAndIntangibleAssetsClassifiedAsInvestingActivities",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInInvestingActivities",
       "weight": -1.0,
       "order": 27.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Purchase of subsidiaries, associates and intangible assets",
        "label": "Purchase Of Subsidiaries Associates And Intangible Assets Classified As Investing Activities",
        "documentation": "The aggregate cash flows used in obtaining control of subsidiaries, associates and/or intangible assets, classified as investing activities.",
        "terseLabel": "Purchase of subsidiaries, associates and intangible assets"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_PurchaseOfTreasuryShares": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "PurchaseOfTreasuryShares",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Purchase Of Treasury Shares",
        "negatedLabel": "Acquisition of treasury shares"
       }
      },
      "en": {
       "role": {
        "documentation": "The decrease in equity resulting from the purchase of treasury shares. [Refer: Treasury shares]"
       }
      }
     },
     "auth_ref": [
      "r246"
     ]
    },
    "ifrs-full_PurchasesFairValueMeasurementAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "PurchasesFairValueMeasurementAssets",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Purchases Fair Value Measurement Assets",
        "terseLabel": "Purchases"
       }
      },
      "en": {
       "role": {
        "documentation": "The increase in the fair value measurement of assets resulting from purchases of those assets. [Refer: At fair value [member]]"
       }
      }
     },
     "auth_ref": [
      "r101"
     ]
    },
    "ifrs-full_PurchasesFairValueMeasurementLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "PurchasesFairValueMeasurementLiabilities",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Purchases Fair Value Measurement Liabilities",
        "terseLabel": "Purchases"
       }
      },
      "en": {
       "role": {
        "documentation": "The increase in the fair value measurement of liabilities resulting from purchases of those liabilities. [Refer: At fair value [member]]"
       }
      }
     },
     "auth_ref": [
      "r101"
     ]
    },
    "ifrs-full_RangeAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "RangeAxis",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail",
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Range [Axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r108",
      "r120",
      "r128",
      "r216",
      "r218",
      "r264"
     ]
    },
    "ifrs-full_RangesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "RangesMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail",
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Ranges [Member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for aggregate ranges. It also represents the standard value for the 'Range' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r108",
      "r120",
      "r128",
      "r216",
      "r218",
      "r264"
     ]
    },
    "ubsag_RatesLinkedIssuedDebtInstrumentsDesignatedAtFairValueThroughProfitOrLoss": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "RatesLinkedIssuedDebtInstrumentsDesignatedAtFairValueThroughProfitOrLoss",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueDetail": {
       "parentTag": "ubsag_DebtSecuritiesIssuedAtFairValueThroughProfitOrLossDesignatedAsUponInitialRecognition",
       "weight": 1.0,
       "order": 4.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Rates Linked Issued Debt Instruments Designated At Fair Value Through Profit Or Loss",
        "terseLabel": "Rates-linked",
        "documentation": "The amount of rates-linked debt instruments that have been issued and are designated at fair value."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_RealEstateLendingMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "RealEstateLendingMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementECLrelevantBalanceSheetAndOffbalanceSheetPositionsIncludingECLAllowancesAndProvisionsNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Real Estate Lending [Member]",
        "terseLabel": "Total real estate lending",
        "documentation": "This member relates to a class of financial assets that represents private clients with mortgages and real estate financing."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_RealEstateLoanMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "RealEstateLoanMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Real Estate Loan [Member]",
        "terseLabel": "Real estate financing",
        "documentation": "This member relates to real estate loan.",
        "verboseLabel": "of which: Real estate financing"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_RealEstateMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "RealEstateMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementComparisonOfShockFactorsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Real Estate [Member]",
        "verboseLabel": "Real estate (annual percentage change, Q4)",
        "documentation": "This member stands for changes in real estate prices."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_RealEstateProvisionMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "RealEstateProvisionMember",
     "presentation": [
      "http://www.ubsag.com/role/ProvisionsAdditionalInformationDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Real Estate Provision [Member]",
        "terseLabel": "Real estate",
        "documentation": "This member stands for a provision for real estate."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_RealEstateRelatedOnerousContractsRestructuringProvision": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "RealEstateRelatedOnerousContractsRestructuringProvision",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/ProvisionsAdditionalInformationDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Real Estate Related Onerous Contracts Restructuring Provision",
        "terseLabel": "Real estate related onerous contracts restructuring provision",
        "documentation": "The amount of provisions for real estate related onerous restructuring contracts. An onerous contract is a contract in which the unavoidable costs of meeting the obligation under the contract exceed the economic benefits expected to be received under it."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ReceivablesFromContractsWithCustomers": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ReceivablesFromContractsWithCustomers",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/OtherFinancialAssetsMeasuredAtAmortizedCostDetail": {
       "parentTag": "ubsag_OtherFinancialAssetsAtAmortisedCost",
       "weight": 1.0,
       "order": 4.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherFinancialAssetsMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Receivables From Contracts With Customers",
        "terseLabel": "Fee- and commission-related receivables"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of an entity\u2019s right to consideration in exchange for goods or services that the entity has transferred to a customer that is unconditional. A right to consideration is unconditional if only the passage of time is required before payment of that consideration is due."
       }
      }
     },
     "auth_ref": [
      "r109",
      "r112"
     ]
    },
    "ifrs-full_ReceivablesFromTaxesOtherThanIncomeTax": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ReceivablesFromTaxesOtherThanIncomeTax",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/OtherNonfinancialAssetsDetail": {
       "parentTag": "ifrs-full_OtherNonfinancialAssets",
       "weight": 1.0,
       "order": 6.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherNonfinancialAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Receivables From Taxes Other Than Income Tax",
        "terseLabel": "VAT, withholding tax and other tax receivables"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of receivables from taxes other than income tax. Income taxes include all domestic and foreign taxes that are based on taxable profits. Income taxes also include taxes, such as withholding taxes, that are payable by a subsidiary, associate or joint arrangement on distributions to the reporting entity."
       }
      }
     },
     "auth_ref": [
      "r250"
     ]
    },
    "ifrs-full_ReclassificationAdjustmentsOnCashFlowHedgesBeforeTax": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ReclassificationAdjustmentsOnCashFlowHedgesBeforeTax",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome": {
       "parentTag": "ifrs-full_OtherComprehensiveIncomeNetOfTaxCashFlowHedges",
       "weight": -1.0,
       "order": 18.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Reclassification Adjustments On Cash Flow Hedges Before Tax",
        "negatedLabel": "Net (gains) / losses reclassified to the income statement from equity",
        "negatedTotalLabel": "Net realized (gains) / losses reclassified to the income statement from equity"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of reclassification adjustments related to cash flow hedges, before tax. Reclassification adjustments are amounts reclassified to profit (loss) in the current period that were recognised in other comprehensive income in the current or previous periods. [Refer: Cash flow hedges [member]; Other comprehensive income]"
       }
      }
     },
     "auth_ref": [
      "r34"
     ]
    },
    "ifrs-full_ReclassificationAdjustmentsOnExchangeDifferencesOnTranslationBeforeTax": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ReclassificationAdjustmentsOnExchangeDifferencesOnTranslationBeforeTax",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome": {
       "parentTag": "ifrs-full_OtherComprehensiveIncomeNetOfTaxExchangeDifferencesOnTranslation",
       "weight": -1.0,
       "order": 6.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Reclassification Adjustments On Exchange Differences On Translation Before Tax",
        "negatedLabel": "Foreign currency translation differences on foreign operations reclassified to the income statement",
        "terseLabel": "Foreign exchange amounts reclassified to the income statement from equity"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of reclassification adjustments related to exchange differences when the financial statements of foreign operations are translated, before tax. Reclassification adjustments are amounts reclassified to profit (loss) in the current period that were recognised in other comprehensive income in the current or previous periods. [Refer: Other comprehensive income]"
       }
      }
     },
     "auth_ref": [
      "r34",
      "r46"
     ]
    },
    "ifrs-full_ReclassificationAdjustmentsOnFinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncomeBeforeTax": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ReclassificationAdjustmentsOnFinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncomeBeforeTax",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome": {
       "parentTag": "ifrs-full_OtherComprehensiveIncomeNetOfTaxFinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncome",
       "weight": -1.0,
       "order": 12.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Reclassification Adjustments On Financial Assets Measured At Fair Value Through Other Comprehensive Income Before Tax",
        "terseLabel": "Net realized (gains) / losses reclassified to the income statement from equity"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of reclassification adjustments related to financial assets measured at fair value through other comprehensive income, before tax. Reclassification adjustments are amounts reclassified to profit (loss) in the current period that were recognised in other comprehensive income in the current or previous periods. [Refer: Financial assets measured at fair value through other comprehensive income; Other comprehensive income]"
       }
      }
     },
     "auth_ref": [
      "r34",
      "r139"
     ]
    },
    "ifrs-full_ReclassificationAdjustmentsOnHedgesOfNetInvestmentsInForeignOperationsBeforeTax": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ReclassificationAdjustmentsOnHedgesOfNetInvestmentsInForeignOperationsBeforeTax",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome": {
       "parentTag": "ifrs-full_OtherComprehensiveIncomeNetOfTaxExchangeDifferencesOnTranslation",
       "weight": -1.0,
       "order": 7.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Reclassification Adjustments On Hedges Of Net Investments In Foreign Operations Before Tax",
        "negatedLabel": "Effective portion of changes in fair value of hedging instruments designated as net investment hedges reclassified to the income statement"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of reclassification adjustments related to hedges of net investments in foreign operations, before tax. Reclassification adjustments are amounts reclassified to profit (loss) in the current period that were recognised in other comprehensive income in the current or previous periods. [Refer: Other comprehensive income]"
       }
      }
     },
     "auth_ref": [
      "r34",
      "r64",
      "r191"
     ]
    },
    "ifrs-full_ReclassificationOfFinancialAssetsOutOfMeasuredAtFairValueThroughOtherComprehensiveIncomeIntoMeasuredAtAmortisedCost": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ReclassificationOfFinancialAssetsOutOfMeasuredAtFairValueThroughOtherComprehensiveIncomeIntoMeasuredAtAmortisedCost",
     "presentation": [
      "http://www.ubsag.com/role/ReclassificationOfFinancialAssetsNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Reclassification Of Financial Assets Out Of Measured At Fair Value Through Other Comprehensive Income Into Measured At Amortised Cost",
        "terseLabel": "Reclassification of financial assets out of measured at fair value through other comprehensive income into measured at amortised cost"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of financial assets reclassified out of the fair value through other comprehensive income measurement category and into the amortised cost measurement category. [Refer: Financial assets]"
       }
      }
     },
     "auth_ref": [
      "r132"
     ]
    },
    "ifrs-full_RecognisedLiabilitiesDefinedBenefitPlan": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "RecognisedLiabilitiesDefinedBenefitPlan",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/OtherNonfinancialLiabilitiesDetail": {
       "parentTag": "ubsag_CompensationrelatedLiabilities",
       "weight": 1.0,
       "order": 6.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherNonfinancialLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Recognised Liabilities Defined Benefit Plan",
        "terseLabel": "of which: net defined benefit liability",
        "verboseLabel": "Total net defined benefit pension and post-employment liability"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of deficit in a defined benefit plan. [Refer: Defined benefit plans [member]]"
       }
      }
     },
     "auth_ref": [
      "r249"
     ]
    },
    "ubsag_RecoveryRatesMeasurementInputMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "RecoveryRatesMeasurementInputMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Recovery Rates Measurement Input [Member]",
        "terseLabel": "Recovery rates",
        "documentation": "This member stands for recovery rates used as a measurement input."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_RecruitmentLoansToFinancialAdvisors": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "RecruitmentLoansToFinancialAdvisors",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/OtherFinancialAssetsMeasuredAtAmortizedCostDetail": {
       "parentTag": "ubsag_OtherFinancialAssetsAtAmortisedCost",
       "weight": 1.0,
       "order": 3.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherFinancialAssetsMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Recruitment Loans To Financial Advisors",
        "documentation": "The amount of recruitment loans to financial advisors.",
        "terseLabel": "Loans to financial advisors"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_ReducedBailOrdered": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ReducedBailOrdered",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Reduced Bail Ordered",
        "terseLabel": "Reduced bail (\"caution\") ordered to be paid",
        "documentation": "The amount of bail (\"caution\") after reduction ordered to be paid."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_RepaymentOfSwissNationalBankFunding": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "RepaymentOfSwissNationalBankFunding",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInFinancingActivities",
       "weight": -1.0,
       "order": 36.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Repayment Of Swiss National Bank Funding",
        "terseLabel": "Repayment of Swiss National Bank funding",
        "documentation": "The cash outflow for repayment of Swiss National Bank funding, classified as financing activities.",
        "negatedLabel": "Repayment of Swiss National Bank funding"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_RepaymentsOfBondsNotesAndDebentures": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "RepaymentsOfBondsNotesAndDebentures",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows": {
       "parentTag": "ifrs-full_CashFlowsFromUsedInFinancingActivities",
       "weight": -1.0,
       "order": 40.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Repayments Of Bonds Notes And Debentures",
        "negatedLabel": "Repayment of debt designated at fair value and long-term debt measured at amortized cost",
        "terseLabel": "Repayment of long-term debt, including financial liabilities designated at fair value"
       }
      },
      "en": {
       "role": {
        "documentation": "The cash outflow for repayments of bonds, notes and debentures."
       }
      }
     },
     "auth_ref": [
      "r257"
     ]
    },
    "srt_ReportableLegalEntitiesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://fasb.org/srt/2023",
     "localname": "ReportableLegalEntitiesMember",
     "presentation": [
      "http://www.ubsag.com/role/SupplementalGuarantorConsolidatedStatementOfCashFlowsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Reportable Legal Entities [Member]",
        "terseLabel": "Reportable legal entities"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_RepurchaseAgreementsAndCashCollateralOnSecuritiesLent": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "RepurchaseAgreementsAndCashCollateralOnSecuritiesLent",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_FinancialLiabilitiesAtAmortisedCost",
       "weight": 1.0,
       "order": 25.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/FVMFinancialInstrumentsNotMeasuredAtFairValueLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "verboseLabel": "Repurchase agreements (newly included in Payables from securities financing transactions)",
        "terseLabel": "Payables from securities financing transactions measured at amortized cost",
        "label": "Repurchase Agreements And Cash Collateral On Securities Lent"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of instruments sold with the intent to reacquire in repurchase agreements and cash collateral on securities lent."
       }
      }
     },
     "auth_ref": [
      "r249"
     ]
    },
    "ubsag_RepurchaseAgreementsAndCashCollateralOnSecuritiesLentTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "RepurchaseAgreementsAndCashCollateralOnSecuritiesLentTransferredAsOfTheMergerDate",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Repurchase Agreements And Cash Collateral On Securities Lent Transferred As Of The Merger Date",
        "terseLabel": "Payables from securities financing transactions",
        "documentation": "The amount of instruments sold with the intent to reacquire in repurchase agreements and cash collateral on securities lent."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ReserveOfCashFlowHedgesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ReserveOfCashFlowHedgesMember",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity",
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquityParenthetical"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Reserve Of Cash Flow Hedges [Member]",
        "terseLabel": "of which: cash flow hedges"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a component of equity representing the accumulated portion of gain (loss) on a hedging instrument that is determined to be an effective hedge for cash flow hedges. [Refer: Cash flow hedges [member]]"
       }
      }
     },
     "auth_ref": [
      "r189",
      "r197"
     ]
    },
    "ifrs-full_ReserveOfChangeInFairValueOfFinancialLiabilityAttributableToChangeInCreditRiskOfLiability": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ReserveOfChangeInFairValueOfFinancialLiabilityAttributableToChangeInCreditRiskOfLiability",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/FVMValuationAdjustmentsReservesOnTheBalanceSheetDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Reserve Of Change In Fair Value Of Financial Liability Attributable To Change In Credit Risk Of Liability",
        "terseLabel": "Unrealized life-to-date gain / (loss)",
        "verboseLabel": "Own credit adjustments on financial liabilities designated at fair value"
       }
      },
      "en": {
       "role": {
        "documentation": "A component of equity representing the accumulated change in fair value of financial liabilities attributable to change in the credit risk of the liabilities. [Refer: Credit risk [member]; Financial liabilities]"
       }
      }
     },
     "auth_ref": [
      "r251"
     ]
    },
    "ifrs-full_ReserveOfExchangeDifferencesOnTranslationMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ReserveOfExchangeDifferencesOnTranslationMember",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity",
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquityParenthetical"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Reserve Of Exchange Differences On Translation [Member]",
        "terseLabel": "of which: foreign currency translation"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a component of equity representing accumulated exchange differences on the translation of financial statements recognised in other comprehensive income. [Refer: Other comprehensive income]"
       }
      }
     },
     "auth_ref": [
      "r47",
      "r197"
     ]
    },
    "ifrs-full_ReserveOfGainsAndLossesOnFinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncomeMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ReserveOfGainsAndLossesOnFinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncomeMember",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity",
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquityParenthetical"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Reserve Of Gains And Losses On Financial Assets Measured At Fair Value Through Other Comprehensive Income [Member]",
        "terseLabel": "of which: financial assets measured at fair value through other comprehensive income"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a component of equity representing the accumulated gains and losses on financial assets measured at fair value through other comprehensive income. [Refer: Financial assets measured at fair value through other comprehensive income; Other comprehensive income]"
       }
      }
     },
     "auth_ref": [
      "r197"
     ]
    },
    "ubsag_Reserveofchangeinfairvalueoffinancialliabilityattributabletochangeincreditriskofliabilitydebtissueddesignatedatfairvalue": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "Reserveofchangeinfairvalueoffinancialliabilityattributabletochangeincreditriskofliabilitydebtissueddesignatedatfairvalue",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/FVMValuationAdjustmentsReservesOnTheBalanceSheetDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Reserve Of Change In Fair Value Of Financial Liability Attributable To Change In Credit Risk Of Liability Debt Issued Designated At Fair Value",
        "verboseLabel": "of which: debt issued designated at fair value",
        "documentation": "A component of equity representing the accumulated change in fair value of debt issued designated at fair value attributable to change in the credit risk of the liabilities."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_Reserveofchangeinfairvalueoffinancialliabilityattributabletochangeincreditriskofliabilityotherfinancialliabilitiesdesignatedatfairvalue": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "Reserveofchangeinfairvalueoffinancialliabilityattributabletochangeincreditriskofliabilityotherfinancialliabilitiesdesignatedatfairvalue",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/FVMValuationAdjustmentsReservesOnTheBalanceSheetDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Reserve Of Change In Fair Value Of Financial Liability Attributable To Change In Credit Risk Of Liability Other Financial Liabilities Designated At Fair Value",
        "verboseLabel": "of which: other financial liabilities designated at fair value",
        "documentation": "A component of equity representing the accumulated change in fair value of other financial liabilities designated at fair value attributable to change in the credit risk of the liabilities."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_ResidentialMortgagebackedSecuritiesAndMortgagesClaimsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ResidentialMortgagebackedSecuritiesAndMortgagesClaimsMember",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Residential Mortgage Backed Securities And Mortgages Claims [Member]",
        "terseLabel": "Claims related to sales of residential mortgage-backed securities and mortgages",
        "documentation": "This member refers to claims related to sales of residential mortgage-backed securities and mortgages."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_RestructuringProvisionMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "RestructuringProvisionMember",
     "presentation": [
      "http://www.ubsag.com/role/ProvisionsAdditionalInformationDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "terseLabel": "Restructuring",
        "label": "Restructuring Provision [Member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a provision for restructuring, such as the sale or termination of a line of business; closure of business locations in a country or region or relocation of activities from one country or region to another; changes in management structure; and fundamental reorganisations that have a material effect on the nature and focus of the entity's operations. [Refer: Other provisions [member]]"
       }
      }
     },
     "auth_ref": [
      "r205"
     ]
    },
    "ifrs-full_RetainedEarnings": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "RetainedEarnings",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_EquityAttributableToOwnersOfParent",
       "weight": 1.0,
       "order": 45.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Retained Earnings",
        "terseLabel": "Retained earnings"
       }
      },
      "en": {
       "role": {
        "documentation": "A component of equity representing the entity's cumulative undistributed earnings or deficit."
       }
      }
     },
     "auth_ref": [
      "r199",
      "r201"
     ]
    },
    "ifrs-full_RetainedEarningsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "RetainedEarningsMember",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity",
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquityParenthetical"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Retained Earnings [Member]",
        "terseLabel": "Retained earnings"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for a component of equity representing an entity's cumulative undistributed earnings or deficit."
       }
      }
     },
     "auth_ref": [
      "r6",
      "r197"
     ]
    },
    "ifrs-full_Revenue": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "Revenue",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/SegmentReportingDetail": {
       "parentTag": null,
       "weight": null,
       "order": null,
       "root": true
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/SegmentReportingDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Revenue",
        "totalLabel": "Total revenues",
        "terseLabel": "Income"
       }
      },
      "en": {
       "role": {
        "documentation": "The income arising in the course of an entity's ordinary activities. Income is increases in assets, or decreases in liabilities, that result in increases in equity, other than those relating to contributions from holders of equity claims."
       }
      }
     },
     "auth_ref": [
      "r27",
      "r92",
      "r130",
      "r173",
      "r178",
      "r184",
      "r185",
      "r187",
      "r195",
      "r196",
      "r208"
     ]
    },
    "ifrs-full_RevenueAndOperatingIncome": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "RevenueAndOperatingIncome",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement": {
       "parentTag": "ifrs-full_ProfitLossBeforeTax",
       "weight": 1.0,
       "order": 11.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Revenue And Operating Income",
        "totalLabel": "Total revenues",
        "terseLabel": "Total revenues"
       }
      },
      "en": {
       "role": {
        "documentation": "The aggregate amount of the entity's revenue and other operating income. [Refer: Revenue]"
       }
      }
     },
     "auth_ref": [
      "r252"
     ]
    },
    "ifrs-full_ReverseRepurchaseAgreementsAndCashCollateralOnSecuritiesBorrowed": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ReverseRepurchaseAgreementsAndCashCollateralOnSecuritiesBorrowed",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_FinancialAssetsAtAmortisedCost",
       "weight": 1.0,
       "order": 5.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/FVMFinancialInstrumentsNotMeasuredAtFairValueAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Reverse Repurchase Agreements And Cash Collateral On Securities Borrowed",
        "terseLabel": "Receivables from securities financing transactions measured at amortized cost",
        "verboseLabel": "Reverse repurchase agreements (newly included in Receivables from securities financing transactions)"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of instruments purchased for resale in reverse repurchase agreements and cash collateral on securities borrowed. [Refer: Repurchase agreements and cash collateral on securities lent]"
       }
      }
     },
     "auth_ref": [
      "r249"
     ]
    },
    "ubsag_ReverseRepurchaseAgreementsAndCashCollateralOnSecuritiesBorrowedMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ReverseRepurchaseAgreementsAndCashCollateralOnSecuritiesBorrowedMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "terseLabel": "Receivables from securities financing transactions measured at amortized cost",
        "label": "Reverse Repurchase Agreements And Cash Collateral On Securities Borrowed [Member]",
        "documentation": "This member relates to reverse repurchase agreements and cash collateral on securities borrowed.",
        "verboseLabel": "Repurchase agreements"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_ReverseRepurchaseAgreementsAndCashCollateralOnSecuritiesBorrowedTransferredAsOfTheMergerDate": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ReverseRepurchaseAgreementsAndCashCollateralOnSecuritiesBorrowedTransferredAsOfTheMergerDate",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Reverse Repurchase Agreements And Cash Collateral On Securities Borrowed Transferred As Of The Merger Date",
        "terseLabel": "Receivables from securities financing transactions",
        "documentation": "The amount of instruments purchased for resale in reverse repurchase agreements and cash collateral on securities borrowed. [Refer: Repurchase agreements and cash collateral on securities lent]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_SCFFMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "SCFFMember",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "terseLabel": "SCFF",
        "label": "SCFF [Member]",
        "documentation": "This member refers to supply chain finance funds matter."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_SSABondsTradingMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "SSABondsTradingMember",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "SSA Bonds Trading [Member]",
        "terseLabel": "Rates-related matters | SSA bonds trading business",
        "documentation": "This member refers to practices in SSA bonds trading business."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_SaleOfTheProportionOfTheShareholdingInMitsubishiCorpUbsRealtyIncHeldByUbs": {
     "xbrltype": "percentItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "SaleOfTheProportionOfTheShareholdingInMitsubishiCorpUbsRealtyIncHeldByUbs",
     "presentation": [
      "http://www.ubsag.com/role/BasisOfAccountingNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Sale Of The Proportion Of The Shareholding In Mitsubishi Corp UBS Realty Inc Held By UBS",
        "terseLabel": "Sale of the proportion of the shareholding in Mitsubishi Corp.-UBS Realty Inc, held by UBS",
        "documentation": "The sale of the proportion of the shareholding in Mitsubishi Corp.-UBS Realty Inc, held by UBS."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_SaleOrIssueOfTreasuryShares": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "SaleOrIssueOfTreasuryShares",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Sale Or Issue Of Treasury Shares",
        "terseLabel": "Other disposal of treasury shares"
       }
      },
      "en": {
       "role": {
        "documentation": "The increase in equity resulting from the sale or issue of treasury shares. [Refer: Treasury shares]"
       }
      }
     },
     "auth_ref": [
      "r246"
     ]
    },
    "ifrs-full_SalesAndMarketingExpense": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "SalesAndMarketingExpense",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesDetail": {
       "parentTag": "ifrs-full_GeneralAndAdministrativeExpense",
       "weight": 1.0,
       "order": 7.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Sales And Marketing Expense",
        "terseLabel": "Marketing and communication"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of expense relating to the marketing and selling of goods or services."
       }
      }
     },
     "auth_ref": [
      "r252"
     ]
    },
    "ifrs-full_SalesFairValueMeasurementAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "SalesFairValueMeasurementAssets",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Sales Fair Value Measurement Assets",
        "negatedLabel": "Sales"
       }
      },
      "en": {
       "role": {
        "documentation": "The decrease in the fair value measurement of assets resulting from sales. [Refer: At fair value [member]]"
       }
      }
     },
     "auth_ref": [
      "r101"
     ]
    },
    "ifrs-full_SalesFairValueMeasurementLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "SalesFairValueMeasurementLiabilities",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Sales Fair Value Measurement Liabilities",
        "negatedLabel": "Sales"
       }
      },
      "en": {
       "role": {
        "documentation": "The decrease in the fair value measurement of liabilities resulting from sales. [Refer: At fair value [member]]"
       }
      }
     },
     "auth_ref": [
      "r101"
     ]
    },
    "ubsag_ScenarioWeights": {
     "xbrltype": "percentItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ScenarioWeights",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementEconomicScenariosAndWeightsAppliedDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The percentage of scenario weights applied.",
        "terseLabel": "Assigned weights",
        "label": "Scenario Weights"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_SegmentAMMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "SegmentAMMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpensereleaseDetail",
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersDetail",
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail",
      "http://www.ubsag.com/role/SegmentReportingDetail",
      "http://www.ubsag.com/role/SegmentReportingNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Segment AM Member [Member]",
        "documentation": "This member stands for the business division Asset Management.",
        "terseLabel": "Asset Management",
        "verboseLabel": "of which: Asset Management"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_SegmentGFMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "SegmentGFMember",
     "presentation": [
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail",
      "http://www.ubsag.com/role/SegmentReportingDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Segment GF [Member]",
        "documentation": "This member stands for Group Functions.",
        "terseLabel": "Group Functions",
        "verboseLabel": "Group Functions - Non-core and Legacy"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_SegmentGIMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "SegmentGIMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpensereleaseDetail",
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersDetail",
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail",
      "http://www.ubsag.com/role/SegmentReportingDetail",
      "http://www.ubsag.com/role/SegmentReportingNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Segment GI [Member]",
        "terseLabel": "Group Items",
        "documentation": "This member stands for Group Items."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_SegmentGWMMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "SegmentGWMMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpensereleaseDetail",
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersDetail",
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail",
      "http://www.ubsag.com/role/SegmentReportingDetail",
      "http://www.ubsag.com/role/SegmentReportingNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Segment GWM [Member]",
        "terseLabel": "Global Wealth Management",
        "documentation": "This member stands for the business division Global Wealth Management.",
        "verboseLabel": "of which: Global Wealth Management"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_SegmentIBMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "SegmentIBMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpensereleaseDetail",
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersDetail",
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail",
      "http://www.ubsag.com/role/SegmentReportingDetail",
      "http://www.ubsag.com/role/SegmentReportingNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Segment IB [Member]",
        "documentation": "This member stands for the business division Investment Bank.",
        "terseLabel": "Investment Bank",
        "verboseLabel": "of which: Investment Bank"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_SegmentNCLMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "SegmentNCLMember",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlowsParenthetical",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpensereleaseDetail",
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersDetail",
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail",
      "http://www.ubsag.com/role/SegmentReportingDetail",
      "http://www.ubsag.com/role/SegmentReportingNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Segment NCL [Member]",
        "terseLabel": "Non-core and Legacy",
        "documentation": "This member stands for the business division Non-core and Legacy."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_SegmentPCBMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "SegmentPCBMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpensereleaseDetail",
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersDetail",
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail",
      "http://www.ubsag.com/role/SegmentReportingDetail",
      "http://www.ubsag.com/role/SegmentReportingNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Segment PCB [Member]",
        "documentation": "This member stands for the business division Personal &amp; Corporate Banking.",
        "terseLabel": "Personal &amp; Corporate Banking",
        "verboseLabel": "of which: Personal &amp; Corporate Banking"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_SegmentsAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "SegmentsAxis",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlowsParenthetical",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpensereleaseDetail",
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersDetail",
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail",
      "http://www.ubsag.com/role/SegmentReportingDetail",
      "http://www.ubsag.com/role/SegmentReportingNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Segments [Axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r55",
      "r111",
      "r176",
      "r203",
      "r223"
     ]
    },
    "ifrs-full_SegmentsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "SegmentsMember",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlowsParenthetical",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpensereleaseDetail",
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersDetail",
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail",
      "http://www.ubsag.com/role/SegmentReportingDetail",
      "http://www.ubsag.com/role/SegmentReportingNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Segments [Member]",
        "terseLabel": "UBS AG",
        "verboseLabel": "Total"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for all segments of an entity. It also represents the standard value for the 'Segments' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r55",
      "r111",
      "r183",
      "r203",
      "r223"
     ]
    },
    "ubsag_SensitivityOfFairValueMeasurementToChangesInUnobservableInputsAssetsAndLiabilitiesTable": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "SensitivityOfFairValueMeasurementToChangesInUnobservableInputsAssetsAndLiabilitiesTable",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsSensitivityToChangesInUnobservableInputAssumptionsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Sensitivity Of Fair Value Measurement To Changes In Unobservable Inputs Assets And Liabilities [Table]",
        "documentation": "Schedule disclosing information related to details of sensitivity of fair value measurements to changes in unobservable input assumptions."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_SettlementAndClearingAccountsAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "SettlementAndClearingAccountsAssets",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/OtherFinancialAssetsMeasuredAtAmortizedCostDetail": {
       "parentTag": "ubsag_OtherFinancialAssetsAtAmortisedCost",
       "weight": 1.0,
       "order": 6.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherFinancialAssetsMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Settlement And Clearing Accounts Assets",
        "terseLabel": "Settlement and clearing accounts",
        "documentation": "The amount of receivables in settlement and clearing accounts."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_SettlementAndClearingAccountsLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "SettlementAndClearingAccountsLiabilities",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/OtherFinancialLiabilitiesMeasuredAtAmortizedCostDetail": {
       "parentTag": "ubsag_OtherFinancialLiabilitiesAtAmortisedCost",
       "weight": 1.0,
       "order": 4.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherFinancialLiabilitiesMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Settlement And Clearing Accounts Liabilities",
        "terseLabel": "Settlement and clearing accounts",
        "documentation": "Amounts payable for money transfers, money orders, and consumer payment service arrangements. Settlement liabilities include amounts payable to intermediaries for global payment transfers."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_SettlementsFairValueMeasurementAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "SettlementsFairValueMeasurementAssets",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Settlements Fair Value Measurement Assets",
        "negatedLabel": "Settlements"
       }
      },
      "en": {
       "role": {
        "documentation": "The decrease in the fair value measurement of assets resulting from settlements. [Refer: At fair value [member]]"
       }
      }
     },
     "auth_ref": [
      "r101"
     ]
    },
    "ifrs-full_SettlementsFairValueMeasurementLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "SettlementsFairValueMeasurementLiabilities",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Settlements Fair Value Measurement Liabilities",
        "negatedLabel": "Settlements"
       }
      },
      "en": {
       "role": {
        "documentation": "The decrease in the fair value measurement of liabilities resulting from settlements. [Refer: At fair value [member]]"
       }
      }
     },
     "auth_ref": [
      "r101"
     ]
    },
    "ubsag_SevereDownsideScenarioMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "SevereDownsideScenarioMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementEconomicScenariosAndWeightsAppliedDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Severe Downside Scenario [Member]",
        "terseLabel": "Global crisis",
        "documentation": "This member stands for severe downside economic scenarios used in the calculation of expected credit losses."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_SevereRussiaUkraineConflictScenarioMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "SevereRussiaUkraineConflictScenarioMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementEconomicScenariosAndWeightsAppliedDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Severe Russia Ukraine Conflict Scenario [Member]",
        "terseLabel": "Severe Russia-Ukraine conflict scenario",
        "documentation": "This member stands for severe Severe Russia-Ukraine conflict scenario used in the calculation of expected credit losses."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ShareOfProfitLossOfAssociatesAndJointVenturesAccountedForUsingEquityMethod": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ShareOfProfitLossOfAssociatesAndJointVenturesAccountedForUsingEquityMethod",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/OtherIncomeDetail": {
       "parentTag": "ifrs-full_OtherIncomeExpenseFromSubsidiariesJointlyControlledEntitiesAndAssociates",
       "weight": 1.0,
       "order": 4.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Share Of Profit Loss Of Associates And Joint Ventures Accounted For Using Equity Method",
        "verboseLabel": "Share of net profits of associates and joint ventures",
        "terseLabel": "of which: share of net profit / (loss)"
       }
      },
      "en": {
       "role": {
        "documentation": "The entity's share of the profit (loss) of associates and joint ventures accounted for using the equity method. [Refer: Associates [member]; Investments accounted for using equity method; Joint ventures [member]; Profit (loss)]"
       }
      }
     },
     "auth_ref": [
      "r29",
      "r174",
      "r182"
     ]
    },
    "ifrs-full_SharePremium": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "SharePremium",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_EquityAttributableToOwnersOfParent",
       "weight": 1.0,
       "order": 43.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Share Premium",
        "terseLabel": "Share premium"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount received or receivable from the issuance of the entity's shares in excess of nominal value."
       }
      }
     },
     "auth_ref": [
      "r199"
     ]
    },
    "ubsag_SharedServiceCosts": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "SharedServiceCosts",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Shared Service Costs",
        "terseLabel": "of which: shared service costs charged by UBS Group AG or its subsidiaries",
        "documentation": "The amount of shared service costs."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_ShipAircraftMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ShipAircraftMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Ship Aircraft [Member]",
        "terseLabel": "Ship / aircraft financing",
        "documentation": "This member relates to ship and aircraft financing.",
        "verboseLabel": "of which: Ship / aircraft financing"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ShorttermInvestmentsClassifiedAsCashEquivalents": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ShorttermInvestmentsClassifiedAsCashEquivalents",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Shortterm Investments Classified As Cash Equivalents",
        "terseLabel": "Money market paper classified as cash equivalents",
        "verboseLabel": "of which: money market paper"
       }
      },
      "en": {
       "role": {
        "documentation": "A classification of cash equivalents representing short-term investments. [Refer: Cash equivalents]"
       }
      }
     },
     "auth_ref": [
      "r260"
     ]
    },
    "ubsag_SignificantUnobservableInputAssetsAndLiabilities": {
     "xbrltype": "decimalItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "SignificantUnobservableInputAssetsAndLiabilities",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Significant Unobservable Input Assets And Liabilities",
        "terseLabel": "Significant unobservable input(s)",
        "documentation": "The value of significant unobservable input used in the measurement of the fair value of assets and liabilities."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_SingaporeCivilLawsuitsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "SingaporeCivilLawsuitsMember",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Singapore Civil Lawsuits [Member]",
        "terseLabel": "Customer account matters | Singapore civil lawsuits",
        "documentation": "This member refers to a civil lawsuit brought in Singapore."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_SmallMediumEnterpriseMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "SmallMediumEnterpriseMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Small Medium Enterprise [Member]",
        "terseLabel": "SME clients",
        "documentation": "This member relates to small and medium-sized enterprise.",
        "verboseLabel": "of which: SME clients"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_SocialSecurityContributions": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "SocialSecurityContributions",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/PersonnelExpensesDetail": {
       "parentTag": "ifrs-full_EmployeeBenefitsExpense",
       "weight": 1.0,
       "order": 5.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/PersonnelExpensesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Social Security Contributions",
        "terseLabel": "Social security",
        "verboseLabel": "Social security related to share-based compensation"
       }
      },
      "en": {
       "role": {
        "documentation": "A class of employee benefits expense that represents social security contributions. [Refer: Employee benefits expense]"
       }
      }
     },
     "auth_ref": [
      "r256"
     ]
    },
    "ifrs-full_StatementOfCashFlowsAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "StatementOfCashFlowsAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Statement Of Cash Flows [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_StatementOfCashFlowsLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "StatementOfCashFlowsLineItems",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows",
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlowsParenthetical"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Statement Of Cash Flows [Line Items]",
        "terseLabel": "Statement Of Cash Flows",
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with domain members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_StatementOfChangesInEquityAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "StatementOfChangesInEquityAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Statement Of Changes In Equity [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_StatementOfChangesInEquityLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "StatementOfChangesInEquityLineItems",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity",
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquityParenthetical"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Statement Of Changes In Equity [Line Items]",
        "terseLabel": "Statement of changes in equity"
       }
      },
      "en": {
       "role": {
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_StatementOfChangesInEquityTable": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "StatementOfChangesInEquityTable",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Statement Of Changes In Equity [Table]"
       }
      },
      "en": {
       "role": {
        "documentation": "Schedule disclosing information related to changes in equity."
       }
      }
     },
     "auth_ref": [
      "r6"
     ]
    },
    "ifrs-full_StatementOfComprehensiveIncomeAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "StatementOfComprehensiveIncomeAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Statement Of Comprehensive Income [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_StatementOfComprehensiveIncomeLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "StatementOfComprehensiveIncomeLineItems",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome",
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncomeParenthetical"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Statement Of Comprehensive Income [Line Items]",
        "terseLabel": "Statement of comprehensive income",
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with domain members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_StatementOfComprehensiveIncomeTable": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "StatementOfComprehensiveIncomeTable",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Statement Of Comprehensive Income [Table]",
        "documentation": "Schedule disclosing information related to details of statement of comprehensive income."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_StatementOfFinancialPositionAbstract": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "StatementOfFinancialPositionAbstract",
     "lang": {
      "en-us": {
       "role": {
        "label": "Statement Of Financial Position [Abstract]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_StatementThatThereWereNoTransfersBetweenLevel1AndLevel2OfFairValueHierarchyAssets": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "StatementThatThereWereNoTransfersBetweenLevel1AndLevel2OfFairValueHierarchyAssets",
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueMeasurementNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Statement That There Were No Transfers Between Level1 And Level2 Of Fair Value Hierarchy Assets",
        "terseLabel": "Statement that there were no transfers between Level 1 and Level 2 of fair value hierarchy, assets"
       }
      },
      "en": {
       "role": {
        "documentation": "The statement that there were no transfers between Level 1 and Level 2 of the fair value hierarchy of assets during the year."
       }
      }
     },
     "auth_ref": [
      "r261"
     ]
    },
    "ifrs-full_StatementThatThereWereNoTransfersBetweenLevel1AndLevel2OfFairValueHierarchyLiabilities": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "StatementThatThereWereNoTransfersBetweenLevel1AndLevel2OfFairValueHierarchyLiabilities",
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueMeasurementNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Statement That There Were No Transfers Between Level 1 And Level 2 Of Fair Value Hierarchy Liabilities",
        "terseLabel": "Statement that there were no transfers between Level 1 and Level 2 of fair value hierarchy, liabilities"
       }
      },
      "en": {
       "role": {
        "documentation": "The statement that there were no transfers between Level 1 and Level 2 of the fair value hierarchy of liabilities during the year."
       }
      }
     },
     "auth_ref": [
      "r261"
     ]
    },
    "ubsag_StructuredSecuritiesFinancingTransactions": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "StructuredSecuritiesFinancingTransactions",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/OtherFinancialLiabilitiesDesignatedAtFairValueDetail": {
       "parentTag": "ubsag_OtherFinancialLiabilitiesAtFairValueThroughProfitOrLossDesignatedAsUponInitialRecognition",
       "weight": 1.0,
       "order": 3.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/OtherFinancialLiabilitiesDesignatedAtFairValueDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Structured Securities Financing Transactions",
        "terseLabel": "Securities financing transactions",
        "documentation": "The amount of structured securities financing transactions."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_StructuredSecuritiesFinancingTransactionsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "StructuredSecuritiesFinancingTransactionsMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail",
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail",
      "http://www.ubsag.com/role/FVMLevel3InstrumentsSensitivityToChangesInUnobservableInputAssumptionsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Structured Securities Financing Transactions [Member]",
        "terseLabel": "Securities financing transactions",
        "documentation": "This member relates to structured securities financing transactions."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_SubordinatedLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "SubordinatedLiabilities",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostDetail": {
       "parentTag": "ifrs-full_NoncurrentDebtInstrumentsIssued",
       "weight": 1.0,
       "order": 7.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Subordinated Liabilities",
        "totalLabel": "Subordinated debt"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of liabilities that are subordinate to other liabilities with respect to claims."
       }
      }
     },
     "auth_ref": [
      "r249"
     ]
    },
    "ubsag_SubordinatedLiabilitiesHighTriggerLossAbsorbingTierOne": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "SubordinatedLiabilitiesHighTriggerLossAbsorbingTierOne",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/FundingFromGroupMeasuredAtAmortizedCostDetail": {
       "parentTag": "ubsag_IntragroupFundingAtAmortisedCost",
       "weight": 1.0,
       "order": 3.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/FundingFromGroupMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Subordinated Liabilities High Trigger Loss Absorbing Tier One",
        "terseLabel": "of which: high-trigger loss-absorbing additional tier 1 capital instruments",
        "documentation": "The amount of liabilities from high-trigger loss-absorbing additional tier 1 capital instruments that are subordinate to other liabilities with respect to claims.",
        "verboseLabel": "Debt eligible as high-trigger loss-absorbing additional tier 1 capital instruments"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_SubordinatedLiabilitiesLowTriggerLossAbsorbingTierOne": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "SubordinatedLiabilitiesLowTriggerLossAbsorbingTierOne",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/FundingFromGroupMeasuredAtAmortizedCostDetail": {
       "parentTag": "ubsag_IntragroupFundingAtAmortisedCost",
       "weight": 1.0,
       "order": 4.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/FundingFromGroupMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Subordinated Liabilities Low Trigger Loss Absorbing Tier One",
        "terseLabel": "of which: low-trigger loss-absorbing additional tier 1 capital instruments",
        "documentation": "The amount of liabilities from low-trigger loss-absorbing additional tier 1 capital instruments that are subordinate to other liabilities with respect to claims.",
        "verboseLabel": "Debt eligible as low-trigger loss-absorbing additional tier 1 capital instruments"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_SubordinatedLiabilitiesNonBaselIIICompliantTierTwo": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "SubordinatedLiabilitiesNonBaselIIICompliantTierTwo",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostDetail": {
       "parentTag": "ifrs-full_SubordinatedLiabilities",
       "weight": 1.0,
       "order": 8.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The amount of liabilities from non Basel III-compliant tier 2 capital instruments that are subordinate to other liabilities with respect to claims.",
        "terseLabel": "of which: eligible as non-Basel III-compliant tier 2 capital instruments",
        "label": "Subordinated Liabilities Non Basel III Compliant Tier Two"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_SupplementalGuarantorInformationLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "SupplementalGuarantorInformationLineItems",
     "presentation": [
      "http://www.ubsag.com/role/SupplementalGuarantorInformationNarrativeDetail",
      "http://www.ubsag.com/role/SupplementalGuarantorInformationRequiredUnderSECRegulations"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Supplemental Guarantor Information [Line Items]",
        "documentation": "Line items represent concepts included in a table. These concepts are used to disclose reportable information associated with domain members defined in one or many axes of the table."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_TLACEligibleSeniorUnsecuredDebtInstrumentsAtFairValueInGoneConcernLossAbsorbingCapacity": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "TLACEligibleSeniorUnsecuredDebtInstrumentsAtFairValueInGoneConcernLossAbsorbingCapacity",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "TLAC Eligible Senior Unsecured Debt Instruments At Fair Value In Gone Concern Loss Absorbing Capacity",
        "documentation": "The amount of total loss-absorbing capacity (TLAC)-eligible senior unsecured debt designated at fair value included in gone concern loss-absorbing capacity.",
        "terseLabel": "of which: debt that contributes to total loss-absorbing capacity",
        "verboseLabel": "Senior unsecured debt that contributes to total loss-absorbing capacity (TLAC)"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_TLACEligibleSubordinatedDebtInstrumentsAtAmortizedCostInGoneConcernLossAbsorbingCapacityIntragroupFunding": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "TLACEligibleSubordinatedDebtInstrumentsAtAmortizedCostInGoneConcernLossAbsorbingCapacityIntragroupFunding",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/FundingFromGroupMeasuredAtAmortizedCostDetail": {
       "parentTag": "ubsag_IntragroupFundingAtAmortisedCost",
       "weight": 1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/FundingFromGroupMeasuredAtAmortizedCostDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "TLAC Eligible Subordinated Debt Instruments At Amortized Cost In Gone Concern Loss Absorbing Capacity Intragroup Funding",
        "terseLabel": "Debt contributing to total loss-absorbing capacity (TLAC)",
        "documentation": "The amount of total loss-absorbing capacity (TLAC)-eligible subordinated bonds designated at amortized cost included in gone concern loss-absorbing capacity."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_TimingOfTransferOfGoodsOrServicesAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "TimingOfTransferOfGoodsOrServicesAxis",
     "presentation": [
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Timing Of Transfer Of Goods Or Services [Axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r220"
     ]
    },
    "ifrs-full_TimingOfTransferOfGoodsOrServicesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "TimingOfTransferOfGoodsOrServicesMember",
     "presentation": [
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Timing Of Transfer Of Goods Or Services [Member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for all timings of the transfer of goods or services in contracts with customers. It also represents the standard value for the 'Timing of transfer of goods or services' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r220"
     ]
    },
    "ifrs-full_TopOfRangeMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "TopOfRangeMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail",
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Top Of Range [Member]",
        "terseLabel": "high",
        "verboseLabel": "Maximum"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for top of a range."
       }
      }
     },
     "auth_ref": [
      "r108",
      "r120",
      "r128",
      "r216",
      "r218",
      "r264"
     ]
    },
    "ubsag_TradedLoansLoansAtFairValueLoanCommitmentsAndGuaranteesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "TradedLoansLoansAtFairValueLoanCommitmentsAndGuaranteesMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsSensitivityToChangesInUnobservableInputAssumptionsDetail",
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Traded Loans Loans At Fair Value Loan Commitments And Guarantees [Member]",
        "terseLabel": "Traded loans, loans measured at fair value, loan commitments and guarantees",
        "documentation": "This member relates to traded loans, loans mandatorily at fair value, loan commitments and guarantees.",
        "verboseLabel": "Financial assets and liabilities at fair value held for trading, Financial assets at fair value not held for trading: Traded loans, loans mandatorily at fair value, loan commitments and guarantees"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_TradingRelatedInquiriesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "TradingRelatedInquiriesMember",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Trading Related Inquiries [Member]",
        "terseLabel": "Foreign exchange, LIBOR and benchmark rates, and other trading practices",
        "documentation": "This member refers to litigation, regulatory and similar matters regarding trading practices."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_TransactionsBetweenTransferorAndTransfereeTotalAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "TransactionsBetweenTransferorAndTransfereeTotalAssets",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Transactions Between Transferor And Transferee Total Assets",
        "documentation": "The amount of assets that have been eliminated from the transferred amount.",
        "terseLabel": "Assets of Credit Suisse AG"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_TransactionsBetweenTransferorAndTransfereeTotalLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "TransactionsBetweenTransferorAndTransfereeTotalLiabilities",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Transactions Between Transferor And Transferee Total Liabilities",
        "documentation": "The amount of liabilities that have been eliminated from the transferred amount.",
        "terseLabel": "Liabilities of Credit Suisse AG"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_TransfersIntoLevel3OfFairValueHierarchyAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "TransfersIntoLevel3OfFairValueHierarchyAssets",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Transfers Into Level 3 Of Fair Value Hierarchy Assets",
        "terseLabel": "Transfers into Level 3"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of transfers of assets into Level 3 of the fair value hierarchy. [Refer: Level 3 of fair value hierarchy [member]]"
       }
      }
     },
     "auth_ref": [
      "r102"
     ]
    },
    "ifrs-full_TransfersIntoLevel3OfFairValueHierarchyLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "TransfersIntoLevel3OfFairValueHierarchyLiabilities",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Transfers Into Level 3 Of Fair Value Hierarchy Liabilities",
        "terseLabel": "Transfers into Level 3"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of transfers of liabilities into Level 3 of the fair value hierarchy. [Refer: Level 3 of fair value hierarchy [member]]"
       }
      }
     },
     "auth_ref": [
      "r102"
     ]
    },
    "ifrs-full_TransfersOutOfLevel3OfFairValueHierarchyAssets": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "TransfersOutOfLevel3OfFairValueHierarchyAssets",
     "crdr": "credit",
     "presentation": [
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Transfers Out Of Level 3 Of Fair Value Hierarchy Assets",
        "negatedLabel": "Transfers out of Level 3"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of transfers of assets out of Level 3 of the fair value hierarchy. [Refer: Level 3 of fair value hierarchy [member]]"
       }
      }
     },
     "auth_ref": [
      "r102"
     ]
    },
    "ifrs-full_TransfersOutOfLevel3OfFairValueHierarchyLiabilities": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "TransfersOutOfLevel3OfFairValueHierarchyLiabilities",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Transfers Out Of Level 3 Of Fair Value Hierarchy Liabilities",
        "negatedLabel": "Transfers out of Level 3"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount of transfers of liabilities out of Level 3 of the fair value hierarchy. [Refer: Level 3 of fair value hierarchy [member]]"
       }
      }
     },
     "auth_ref": [
      "r102"
     ]
    },
    "ubsag_TravelAndEntertainmentExpense": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "TravelAndEntertainmentExpense",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesDetail": {
       "parentTag": "ifrs-full_GeneralAndAdministrativeExpense",
       "weight": 1.0,
       "order": 8.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Travel And Entertainment Expense",
        "terseLabel": "Travel and entertainment",
        "documentation": "The amount of expense arising from travel and entertainment."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_TreasuryShares": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "TreasuryShares",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet": {
       "parentTag": "ifrs-full_EquityAttributableToOwnersOfParent",
       "weight": -1.0,
       "order": 44.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Treasury Shares",
        "negatedLabel": "Treasury shares"
       }
      },
      "en": {
       "role": {
        "documentation": "An entity\u2019s own equity instruments, held by the entity or other members of the consolidated group."
       }
      }
     },
     "auth_ref": [
      "r51",
      "r199"
     ]
    },
    "ifrs-full_TreasurySharesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "TreasurySharesMember",
     "presentation": [
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity",
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquityParenthetical"
     ],
     "lang": {
      "en-us": {
       "role": {
        "terseLabel": "Treasury shares",
        "label": "Treasury Shares [Member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for the entity\u2019s own equity instruments, held by the entity or other members of the consolidated group."
       }
      }
     },
     "auth_ref": [
      "r6"
     ]
    },
    "ifrs-full_TwelvemonthExpectedCreditLossesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "TwelvemonthExpectedCreditLossesMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpenseReleaseNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpensereleaseDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Twelve month Expected Credit Losses [Member]",
        "terseLabel": "Twelve-month expected credit losses"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for the portion of lifetime expected credit losses that represent the expected credit losses that result from default events on a financial instrument that are possible within the 12 months after the reporting date. [Refer: Type of measurement of expected credit losses [member]; Lifetime expected credit losses [member]]"
       }
      }
     },
     "auth_ref": [
      "r147",
      "r154"
     ]
    },
    "ifrs-full_TypeOfMeasurementOfExpectedCreditLossesAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "TypeOfMeasurementOfExpectedCreditLossesAxis",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpenseReleaseNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpensereleaseDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Type Of Measurement Of Expected Credit Losses [Axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r151",
      "r158"
     ]
    },
    "ifrs-full_TypeOfMeasurementOfExpectedCreditLossesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "TypeOfMeasurementOfExpectedCreditLossesMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpenseReleaseNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpensereleaseDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Type Of Measurement Of Expected Credit Losses [Member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for all types of measurement of expected credit losses. Expected credit losses are the weighted average of credit losses with the respective risks of a default occurring as the weights. This member also represents the standard value for the 'Type of measurement of expected credit losses' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r151",
      "r158"
     ]
    },
    "ifrs-full_TypesOfFinancialAssetsAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "TypesOfFinancialAssetsAxis",
     "presentation": [
      "http://www.ubsag.com/role/OffsettingFinancialAssetsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Types Of Financial Assets [Axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r168",
      "r169"
     ]
    },
    "ifrs-full_TypesOfFinancialLiabilitiesAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "TypesOfFinancialLiabilitiesAxis",
     "presentation": [
      "http://www.ubsag.com/role/OffsettingFinancialLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Types Of Financial Liabilities [Axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r168",
      "r169"
     ]
    },
    "ifrs-full_TypesOfInstrumentMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "TypesOfInstrumentMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail",
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail",
      "http://www.ubsag.com/role/FVMLevel3InstrumentsSensitivityToChangesInUnobservableInputAssumptionsDetail",
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Types Of Instrument [Member]",
        "terseLabel": "Total"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for all types of financial instruments. It also represents the standard value for the 'Continuing involvement in derecognised financial assets by type of instrument' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r232"
     ]
    },
    "ifrs-full_TypesOfRisksAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "TypesOfRisksAxis",
     "presentation": [
      "http://www.ubsag.com/role/DerivativeInstrumentsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Types Of Risks [Axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r121",
      "r122",
      "r123",
      "r125",
      "r141",
      "r145",
      "r146"
     ]
    },
    "ifrs-full_TypesOfRisksMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "TypesOfRisksMember",
     "presentation": [
      "http://www.ubsag.com/role/DerivativeInstrumentsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Types Of Risks [Member]",
        "terseLabel": "Types of risk",
        "verboseLabel": "Interest rate contracts"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for all types of risks. It also represents the standard value for the 'Types of risks' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r121",
      "r122",
      "r123",
      "r125",
      "r141",
      "r145",
      "r146"
     ]
    },
    "ubsag_UBSAGCrossBorderWealthManagementBusinessesLawsuitsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "UBSAGCrossBorderWealthManagementBusinessesLawsuitsMember",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "UBS AG Cross Border Wealth Management Businesses Lawsuits [Member]",
        "terseLabel": "Inquiries regarding cross-border wealth management businesses | Investigations in France involving UBS AG",
        "documentation": "This member refers to inquiries regarding cross-border wealth management businesses."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_UBSAGMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "UBSAGMember",
     "presentation": [
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAG",
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGAssetsLiabilitiesAndEquityTransferredToUBSAGOnTheMergerDateDetail",
      "http://www.ubsag.com/role/AccountingForTheMergerOfUBSAGAndCreditSuisseAGTables",
      "http://www.ubsag.com/role/BasisOfAccounting",
      "http://www.ubsag.com/role/BasisOfAccountingCurrencyTranslationRatesDetail",
      "http://www.ubsag.com/role/BasisOfAccountingNarrativeDetail",
      "http://www.ubsag.com/role/BasisOfAccountingPolicy",
      "http://www.ubsag.com/role/BasisOfAccountingTables",
      "http://www.ubsag.com/role/ChangesInAccountingPoliciesComparabilityAndAdjustments",
      "http://www.ubsag.com/role/ConsolidatedBalanceSheet",
      "http://www.ubsag.com/role/ConsolidatedIncomeStatement",
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlows",
      "http://www.ubsag.com/role/ConsolidatedStatementOfCashFlowsParenthetical",
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquity",
      "http://www.ubsag.com/role/ConsolidatedStatementOfChangesInEquityParenthetical",
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncome",
      "http://www.ubsag.com/role/ConsolidatedStatementOfComprehensiveIncomeParenthetical",
      "http://www.ubsag.com/role/CurrencyTranslationRates",
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValue",
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueDetail",
      "http://www.ubsag.com/role/DebtIssuedDesignatedAtFairValueTable",
      "http://www.ubsag.com/role/DebtIssuedHeldAtAmortizedCost",
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostDetail",
      "http://www.ubsag.com/role/DebtIssuedMeasuredAtAmortizedCostTables",
      "http://www.ubsag.com/role/DerivativeInstruments",
      "http://www.ubsag.com/role/DerivativeInstrumentsDetail",
      "http://www.ubsag.com/role/DerivativeInstrumentsTables",
      "http://www.ubsag.com/role/DocumentAndEntityInformation",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurement",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementChangesToECLModelsScenariosScenarioWeightsAndPostmodelAdjustmentsNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementComparisonOfShockFactorsDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail1",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCoverageRatiosDetail2",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpenseReleaseNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementCreditLossExpensereleaseDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementECLrelevantBalanceSheetAndOffbalanceSheetPositionsIncludingECLAllowancesAndProvisionsNarrativeDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementEconomicScenariosAndWeightsAppliedDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOffbalanceSheetFinancialAssetsSubjectToECLDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementOnbalanceSheetFinancialAssetsSubjectToECLDetail",
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementTables",
      "http://www.ubsag.com/role/FVMFairValueHierarchyAssetsDetail",
      "http://www.ubsag.com/role/FVMFairValueHierarchyLiabilitiesDetail",
      "http://www.ubsag.com/role/FVMFairValueMeasurementNarrativeDetail",
      "http://www.ubsag.com/role/FVMFinancialInstrumentsNotMeasuredAtFairValueAssetsDetail",
      "http://www.ubsag.com/role/FVMFinancialInstrumentsNotMeasuredAtFairValueLiabilitiesDetail",
      "http://www.ubsag.com/role/FVMLevel3InstrumentsSensitivityToChangesInUnobservableInputAssumptionsDetail",
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsAssetsDetail",
      "http://www.ubsag.com/role/FVMMovementsOfLevel3InstrumentsLiabilitiesDetail",
      "http://www.ubsag.com/role/FVMValuationAdjustmentsDeferredDay1PLDetail",
      "http://www.ubsag.com/role/FVMValuationAdjustmentsReservesOnTheBalanceSheetDetail",
      "http://www.ubsag.com/role/FairValueMeasurement",
      "http://www.ubsag.com/role/FairValueMeasurementTables",
      "http://www.ubsag.com/role/FundingFromGroupMeasuredAtAmortizedCost",
      "http://www.ubsag.com/role/FundingFromGroupMeasuredAtAmortizedCostDetail",
      "http://www.ubsag.com/role/FundingFromGroupMeasuredAtAmortizedCostTables",
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpenses",
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesDetail",
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesTables",
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMatters",
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersDetail",
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail",
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersTables",
      "http://www.ubsag.com/role/NetFeeAndCommissionIncome",
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail",
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeTables",
      "http://www.ubsag.com/role/NetInterestIncome",
      "http://www.ubsag.com/role/NetInterestIncomeDetail",
      "http://www.ubsag.com/role/NetInterestIncomeTables",
      "http://www.ubsag.com/role/OffsettingFinancialAssetsDetail",
      "http://www.ubsag.com/role/OffsettingFinancialLiabilitiesDetail",
      "http://www.ubsag.com/role/OtherAssetsAndLiabilities",
      "http://www.ubsag.com/role/OtherAssetsAndLiabilitiesTables",
      "http://www.ubsag.com/role/OtherFinancialAssetsMeasuredAtAmortizedCostDetail",
      "http://www.ubsag.com/role/OtherFinancialLiabilitiesDesignatedAtFairValueDetail",
      "http://www.ubsag.com/role/OtherFinancialLiabilitiesMeasuredAtAmortizedCostDetail",
      "http://www.ubsag.com/role/OtherIncome",
      "http://www.ubsag.com/role/OtherIncomeDetail",
      "http://www.ubsag.com/role/OtherIncomeTables",
      "http://www.ubsag.com/role/OtherNonfinancialAssetsDetail",
      "http://www.ubsag.com/role/OtherNonfinancialLiabilitiesDetail",
      "http://www.ubsag.com/role/PersonnelExpenses",
      "http://www.ubsag.com/role/PersonnelExpensesDetail",
      "http://www.ubsag.com/role/PersonnelExpensesTables",
      "http://www.ubsag.com/role/Provisions",
      "http://www.ubsag.com/role/ProvisionsAdditionalInformationDetail",
      "http://www.ubsag.com/role/ProvisionsAndContingentLiabilitiesTables",
      "http://www.ubsag.com/role/ProvisionsDetail",
      "http://www.ubsag.com/role/ReclassificationOfFinancialAssetsNarrativeDetail",
      "http://www.ubsag.com/role/SegmentReporting",
      "http://www.ubsag.com/role/SegmentReportingDetail",
      "http://www.ubsag.com/role/SegmentReportingNarrativeDetail",
      "http://www.ubsag.com/role/SegmentReportingTables",
      "http://www.ubsag.com/role/SupplementalGuarantorConsolidatedStatementOfCashFlowsDetail",
      "http://www.ubsag.com/role/SupplementalGuarantorInformationNarrativeDetail",
      "http://www.ubsag.com/role/SupplementalGuarantorInformationRequiredUnderSECRegulations"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "UBS AG [Member]",
        "terseLabel": "UBS AG",
        "documentation": "This member refers to UBS AG",
        "verboseLabel": "UBS AG (consolidated)"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_UBSFranceSACrossBorderWealthManagementBusinessesLawsuitsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "UBSFranceSACrossBorderWealthManagementBusinessesLawsuitsMember",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersNarrativeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "UBS France SA Cross Border Wealth Management Businesses Lawsuits [Member]",
        "terseLabel": "Inquiries regarding cross-border wealth management businesses | Investigations in France involving UBS (France) S.A.",
        "documentation": "This member refers to inquiries regarding cross-border wealth management businesses."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_UBSSwitzerlandAGGuarantorSubsidiariesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "UBSSwitzerlandAGGuarantorSubsidiariesMember",
     "presentation": [
      "http://www.ubsag.com/role/SupplementalGuarantorConsolidatedStatementOfCashFlowsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "UBS Switzerland AG Guarantor Subsidiaries [Member]",
        "terseLabel": "UBS Switzerland AG",
        "documentation": "UBS Switzerland AG which has guaranteed the issue of securities by another subsidiary of the parent or has guaranteed the issue of securities by the parent.",
        "verboseLabel": "UBS Switzerland AG (standalone)"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_UKAndGermanBankLevies": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "UKAndGermanBankLevies",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/GeneralAndAdministrativeExpensesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "UK And German Bank Levies",
        "terseLabel": "of which: UK and German bank levies",
        "documentation": "The net amount of UK and German bank levies."
       }
      }
     },
     "auth_ref": []
    },
    "country_US": {
     "xbrltype": "domainItemType",
     "nsuri": "http://xbrl.sec.gov/country/2023",
     "localname": "US",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementComparisonOfShockFactorsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "United States [Member]",
        "verboseLabel": "United States",
        "terseLabel": "US"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_UnderwritingFees": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "UnderwritingFees",
     "crdr": "credit",
     "calculation": {
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail": {
       "parentTag": "ifrs-full_FeeAndCommissionIncome",
       "weight": 1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/NetFeeAndCommissionIncomeDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Underwriting Fees",
        "documentation": "The amount of income recognised from underwriting transactions.",
        "terseLabel": "Underwriting Fees"
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_UnemploymentRateMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "UnemploymentRateMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementComparisonOfShockFactorsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Unemployment Rate [Member]",
        "verboseLabel": "Unemployment rate (%, annual average)",
        "documentation": "This member stands for unemployment rate."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_UnobservableInputsAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "UnobservableInputsAxis",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Unobservable Inputs [Axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r99",
      "r263"
     ]
    },
    "ifrs-full_UnobservableInputsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "UnobservableInputsMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Unobservable Inputs [Member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for all the unobservable inputs. It also represents the standard value for the 'Unobservable inputs' axis if no other member is used."
       }
      }
     },
     "auth_ref": [
      "r99",
      "r263"
     ]
    },
    "ubsag_UnsettledPurchaseOfNonDerivativeFinancialInstrumentsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "UnsettledPurchaseOfNonDerivativeFinancialInstrumentsMember",
     "presentation": [
      "http://www.ubsag.com/role/DerivativeInstrumentsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Unsettled Purchase Of Non Derivative Financial Instruments [Member]",
        "terseLabel": "Unsettled purchases of non-derivative financial instruments",
        "documentation": "This member relates to unsettled purchases of non-derivative financial instruments."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_UnsettledSalesOfNonDerivativeFinancialInstrumentsMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "UnsettledSalesOfNonDerivativeFinancialInstrumentsMember",
     "presentation": [
      "http://www.ubsag.com/role/DerivativeInstrumentsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Unsettled Sales Of Non Derivative Financial Instruments [Member]",
        "terseLabel": "Unsettled sales of non-derivative financial instruments",
        "documentation": "This member relates to unsettled sales of non-derivative financial instruments."
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_UnusedProvisionReversedOtherProvisions": {
     "xbrltype": "monetaryItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "UnusedProvisionReversedOtherProvisions",
     "crdr": "debit",
     "presentation": [
      "http://www.ubsag.com/role/LitigationRegulatoryAndSimilarMattersDetail",
      "http://www.ubsag.com/role/ProvisionsAdditionalInformationDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "negatedLabel": "Release of provisions recognized in the income statement",
        "label": "Unused Provision Reversed Other Provisions"
       }
      },
      "en": {
       "role": {
        "documentation": "The amount reversed for unused other provisions. [Refer: Other provisions]"
       }
      }
     },
     "auth_ref": [
      "r58"
     ]
    },
    "ubsag_UpsideScenarioMember": {
     "xbrltype": "domainItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "UpsideScenarioMember",
     "presentation": [
      "http://www.ubsag.com/role/ExpectedCreditLossMeasurementEconomicScenariosAndWeightsAppliedDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Upside Scenario [Member]",
        "terseLabel": "Asset price inflation",
        "documentation": "This member stands for upside economic scenarios used in the calculation of expected credit losses."
       }
      }
     },
     "auth_ref": []
    },
    "ubsag_ValuationAdjustmentReservesOnTheBalanceSheetLineItems": {
     "xbrltype": "stringItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "ValuationAdjustmentReservesOnTheBalanceSheetLineItems",
     "presentation": [
      "http://www.ubsag.com/role/FVMValuationAdjustmentsReservesOnTheBalanceSheetDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Valuation Adjustment Reserves On The Balance Sheet [Line Items]"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_ValuationTechniquesMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ValuationTechniquesMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Valuation Techniques [Member]"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for valuation techniques used by the entity to measure fair value. It also represents the standard value for the 'Valuation techniques used in fair value measurement' axis if no other member is used. [Refer: At fair value [member]]"
       }
      }
     },
     "auth_ref": [
      "r99"
     ]
    },
    "ifrs-full_ValuationTechniquesUsedInFairValueMeasurementAxis": {
     "xbrltype": "stringItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "ValuationTechniquesUsedInFairValueMeasurementAxis",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Valuation Techniques Used In Fair Value Measurement [Axis]"
       }
      },
      "en": {
       "role": {
        "documentation": "The axis of a table defines the relationship between the members in the table and the line items or concepts that complete the table."
       }
      }
     },
     "auth_ref": [
      "r99"
     ]
    },
    "ubsag_WagesAndSalariesAndVariableCompensation": {
     "xbrltype": "monetaryItemType",
     "nsuri": "http://www.ubsag.com/20240630",
     "localname": "WagesAndSalariesAndVariableCompensation",
     "crdr": "debit",
     "calculation": {
      "http://www.ubsag.com/role/PersonnelExpensesDetail": {
       "parentTag": "ifrs-full_EmployeeBenefitsExpense",
       "weight": 1.0,
       "order": 2.0
      }
     },
     "presentation": [
      "http://www.ubsag.com/role/PersonnelExpensesDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "documentation": "The amount of salaries and variable compensation.",
        "terseLabel": "Salaries and variable compensation",
        "label": "Wages And Salaries And Variable Compensation"
       }
      }
     },
     "auth_ref": []
    },
    "ifrs-full_WeightedAverageMember": {
     "xbrltype": "domainItemType",
     "nsuri": "https://xbrl.ifrs.org/taxonomy/2023-03-23/ifrs-full",
     "localname": "WeightedAverageMember",
     "presentation": [
      "http://www.ubsag.com/role/FVMLevel3InstrumentsValuationTechniquesAndInputsDetail"
     ],
     "lang": {
      "en-us": {
       "role": {
        "label": "Weighted Average [Member]",
        "terseLabel": "weighted average",
        "verboseLabel": "Average"
       }
      },
      "en": {
       "role": {
        "documentation": "This member stands for an average in which each quantity to be averaged is assigned a weight that determines the relative effect of each quantity on the average."
       }
      }
     },
     "auth_ref": [
      "r108",
      "r120",
      "r216",
      "r218",
      "r264"
     ]
    }
   }
  }
 },
 "std_ref": {
  "r0": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "104",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_104&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r1": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "106",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_106_a&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r2": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "106",
   "Subparagraph": "d",
   "Clause": "i",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_106_d_i&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r3": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "106",
   "Subparagraph": "d",
   "Clause": "ii",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_106_d_ii&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r4": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "106",
   "Subparagraph": "d",
   "Clause": "iii",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_106_d_iii&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r5": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "106",
   "Subparagraph": "d",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_106_d&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r6": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "106",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_106&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r7": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "117",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_117&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r8": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "122",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_122&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r9": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "54",
   "Subparagraph": "e",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_54_e&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r10": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "54",
   "Subparagraph": "i",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_54_i&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r11": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "54",
   "Subparagraph": "l",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_54_l&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r12": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "54",
   "Subparagraph": "n",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_54_n&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r13": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "54",
   "Subparagraph": "o",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_54_o&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r14": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "54",
   "Subparagraph": "q",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_54_q&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r15": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "54",
   "Subparagraph": "r",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_54_r&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r16": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "55",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_55&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r17": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "56",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_56&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r18": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "61",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_61_a&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r19": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "61",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_61&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r20": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "7",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_7&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r21": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "78",
   "Subparagraph": "e",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_78_e&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r22": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "79",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_79_b&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r23": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "81A",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_81A_a&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r24": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "81A",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_81A_b&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r25": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "81A",
   "Subparagraph": "c",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_81A_c&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r26": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "81B",
   "Subparagraph": "a",
   "Clause": "i",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_81B_a_i&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r27": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "82",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_82_a&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r28": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "82",
   "Subparagraph": "ba",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_82_ba&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r29": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "82",
   "Subparagraph": "c",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_82_c&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r30": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "82",
   "Subparagraph": "d",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_82_d&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r31": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "90",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_90&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r32": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "91",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_91_a&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r33": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "91",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_91_b&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r34": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "92",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_92&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r35": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "98",
   "Subparagraph": "f",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_98_f&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r36": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "99",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_99&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r37": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "12",
   "IssueDate": "2023-01-01",
   "Paragraph": "79",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=12&code=ifrs-tx-2023-en-r&anchor=para_79&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r38": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "12",
   "IssueDate": "2023-01-01",
   "Paragraph": "81",
   "Subparagraph": "ab",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=12&code=ifrs-tx-2023-en-r&anchor=para_81_ab&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r39": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "12",
   "IssueDate": "2023-01-01",
   "Paragraph": "81",
   "Subparagraph": "c",
   "Clause": "i",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=12&code=ifrs-tx-2023-en-r&anchor=para_81_c_i&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r40": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "12",
   "IssueDate": "2023-01-01",
   "Paragraph": "81",
   "Subparagraph": "c",
   "Clause": "ii",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=12&code=ifrs-tx-2023-en-r&anchor=para_81_c_ii&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r41": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "12",
   "IssueDate": "2023-01-01",
   "Paragraph": "81",
   "Subparagraph": "g",
   "Clause": "i",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=12&code=ifrs-tx-2023-en-r&anchor=para_81_g_i&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r42": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "16",
   "IssueDate": "2023-01-01",
   "Paragraph": "73",
   "Subparagraph": "d",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=16&code=ifrs-tx-2023-en-r&anchor=para_73_d&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r43": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "16",
   "IssueDate": "2023-01-01",
   "Paragraph": "73",
   "Subparagraph": "e",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=16&code=ifrs-tx-2023-en-r&anchor=para_73_e&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r44": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "19",
   "IssueDate": "2023-01-01",
   "Paragraph": "142",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=19&code=ifrs-tx-2023-en-r&anchor=para_142&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r45": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "19",
   "IssueDate": "2023-01-01",
   "Section": "Scope",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=19&code=ifrs-tx-2023-en-r&doctype=Standard&dita_xref=IAS19_g2-7_TI",
   "URIDate": "2023-03-23"
  },
  "r46": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "21",
   "IssueDate": "2023-01-01",
   "Paragraph": "48",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=21&code=ifrs-tx-2023-en-r&anchor=para_48&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r47": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "21",
   "IssueDate": "2023-01-01",
   "Paragraph": "52",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=21&code=ifrs-tx-2023-en-r&anchor=para_52_b&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r48": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "21",
   "IssueDate": "2023-01-01",
   "Section": "Disclosure",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=21&code=ifrs-tx-2023-en-r&doctype=Standard&dita_xref=IAS21_g51-57_TI",
   "URIDate": "2023-03-23"
  },
  "r49": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "26",
   "IssueDate": "2023-01-01",
   "Paragraph": "35",
   "Subparagraph": "b",
   "Clause": "iv",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=26&code=ifrs-tx-2023-en-r&anchor=para_35_b_iv&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r50": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "26",
   "IssueDate": "2023-01-01",
   "Paragraph": "35",
   "Subparagraph": "b",
   "Clause": "viii",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=26&code=ifrs-tx-2023-en-r&anchor=para_35_b_viii&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r51": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "32",
   "IssueDate": "2023-01-01",
   "Paragraph": "34",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=32&code=ifrs-tx-2023-en-r&anchor=para_34&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r52": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "33",
   "IssueDate": "2023-01-01",
   "Paragraph": "66",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=33&code=ifrs-tx-2023-en-r&anchor=para_66&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r53": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "33",
   "IssueDate": "2023-01-01",
   "Paragraph": "67",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=33&code=ifrs-tx-2023-en-r&anchor=para_67&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r54": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "33",
   "IssueDate": "2023-01-01",
   "Paragraph": "70",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=33&code=ifrs-tx-2023-en-r&anchor=para_70_a&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r55": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "36",
   "IssueDate": "2023-01-01",
   "Paragraph": "130",
   "Subparagraph": "d",
   "Clause": "ii",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=36&code=ifrs-tx-2023-en-r&anchor=para_130_d_ii&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r56": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "37",
   "IssueDate": "2023-01-01",
   "Paragraph": "84",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=37&code=ifrs-tx-2023-en-r&anchor=para_84_b&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r57": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "37",
   "IssueDate": "2023-01-01",
   "Paragraph": "84",
   "Subparagraph": "c",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=37&code=ifrs-tx-2023-en-r&anchor=para_84_c&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r58": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "37",
   "IssueDate": "2023-01-01",
   "Paragraph": "84",
   "Subparagraph": "d",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=37&code=ifrs-tx-2023-en-r&anchor=para_84_d&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r59": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "37",
   "IssueDate": "2023-01-01",
   "Paragraph": "84",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=37&code=ifrs-tx-2023-en-r&anchor=para_84&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r60": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "37",
   "IssueDate": "2023-01-01",
   "Paragraph": "86",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=37&code=ifrs-tx-2023-en-r&anchor=para_86&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r61": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "38",
   "IssueDate": "2023-01-01",
   "Paragraph": "118",
   "Subparagraph": "c",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=38&code=ifrs-tx-2023-en-r&anchor=para_118_c&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r62": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "38",
   "IssueDate": "2023-01-01",
   "Paragraph": "118",
   "Subparagraph": "e",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=38&code=ifrs-tx-2023-en-r&anchor=para_118_e&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r63": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "39",
   "IssueDate": "2023-01-01",
   "Paragraph": "102",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=39&code=ifrs-tx-2023-en-r&anchor=para_102_a&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r64": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "39",
   "IssueDate": "2023-01-01",
   "Paragraph": "102",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=39&code=ifrs-tx-2023-en-r&anchor=para_102&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r65": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "40",
   "IssueDate": "2023-01-01",
   "Paragraph": "32A",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=40&code=ifrs-tx-2023-en-r&anchor=para_32A&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r66": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "40",
   "IssueDate": "2023-01-01",
   "Paragraph": "76",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=40&code=ifrs-tx-2023-en-r&anchor=para_76&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r67": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "40",
   "IssueDate": "2023-01-01",
   "Paragraph": "79",
   "Subparagraph": "c",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=40&code=ifrs-tx-2023-en-r&anchor=para_79_c&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r68": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "40",
   "IssueDate": "2023-01-01",
   "Paragraph": "79",
   "Subparagraph": "d",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=40&code=ifrs-tx-2023-en-r&anchor=para_79_d&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r69": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "41",
   "IssueDate": "2023-01-01",
   "Paragraph": "50",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=41&code=ifrs-tx-2023-en-r&anchor=para_50&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r70": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "41",
   "IssueDate": "2023-01-01",
   "Paragraph": "54",
   "Subparagraph": "f",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=41&code=ifrs-tx-2023-en-r&anchor=para_54_f&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r71": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "10",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2023-en-r&anchor=para_10&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r72": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "18",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2023-en-r&anchor=para_18_b&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r73": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "20",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2023-en-r&anchor=para_20&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r74": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "21",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2023-en-r&anchor=para_21&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r75": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "25",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2023-en-r&anchor=para_25&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r76": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "28",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2023-en-r&anchor=para_28&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r77": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "31",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2023-en-r&anchor=para_31&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r78": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "35",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2023-en-r&anchor=para_35&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r79": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "40",
   "Subparagraph": "c",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2023-en-r&anchor=para_40_c&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r80": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "45",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2023-en-r&anchor=para_45&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r81": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "50",
   "Subparagraph": "d",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2023-en-r&anchor=para_50_d&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r82": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "8",
   "IssueDate": "2023-01-01",
   "Paragraph": "30",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=8&code=ifrs-tx-2023-en-r&anchor=para_30_b&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r83": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IAS",
   "Number": "8",
   "IssueDate": "2023-01-01",
   "Section": "Accounting policies",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=8&code=ifrs-tx-2023-en-r&doctype=Standard&dita_xref=IAS08_g7-31_TI",
   "URIDate": "2023-03-23"
  },
  "r84": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "24",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=1&code=ifrs-tx-2023-en-r&anchor=para_24_a&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r85": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "24",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=1&code=ifrs-tx-2023-en-r&anchor=para_24_b&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r86": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "32",
   "Subparagraph": "a",
   "Clause": "i",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=1&code=ifrs-tx-2023-en-r&anchor=para_32_a_i&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r87": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "32",
   "Subparagraph": "a",
   "Clause": "ii",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=1&code=ifrs-tx-2023-en-r&anchor=para_32_a_ii&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r88": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "10",
   "IssueDate": "2023-01-01",
   "Paragraph": "22",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=10&code=ifrs-tx-2023-en-r&anchor=para_22&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r89": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "12",
   "IssueDate": "2023-01-01",
   "Paragraph": "12",
   "Subparagraph": "e",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=12&code=ifrs-tx-2023-en-r&anchor=para_12_e&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r90": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "12",
   "IssueDate": "2023-01-01",
   "Paragraph": "12",
   "Subparagraph": "f",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=12&code=ifrs-tx-2023-en-r&anchor=para_12_f&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r91": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "12",
   "IssueDate": "2023-01-01",
   "Paragraph": "B12",
   "Subparagraph": "b",
   "Clause": "ix",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=12&code=ifrs-tx-2023-en-r&anchor=para_B12_b_ix&doctype=Appendix&subtype=B",
   "URIDate": "2023-03-23"
  },
  "r92": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "12",
   "IssueDate": "2023-01-01",
   "Paragraph": "B12",
   "Subparagraph": "b",
   "Clause": "v",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=12&code=ifrs-tx-2023-en-r&anchor=para_B12_b_v&doctype=Appendix&subtype=B",
   "URIDate": "2023-03-23"
  },
  "r93": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "12",
   "IssueDate": "2023-01-01",
   "Paragraph": "B12",
   "Subparagraph": "b",
   "Clause": "viii",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=12&code=ifrs-tx-2023-en-r&anchor=para_B12_b_viii&doctype=Appendix&subtype=B",
   "URIDate": "2023-03-23"
  },
  "r94": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "12",
   "IssueDate": "2023-01-01",
   "Paragraph": "B13",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=12&code=ifrs-tx-2023-en-r&anchor=para_B13_a&doctype=Appendix&subtype=B",
   "URIDate": "2023-03-23"
  },
  "r95": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "12",
   "IssueDate": "2023-01-01",
   "Paragraph": "B13",
   "Subparagraph": "g",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=12&code=ifrs-tx-2023-en-r&anchor=para_B13_g&doctype=Appendix&subtype=B",
   "URIDate": "2023-03-23"
  },
  "r96": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "12",
   "IssueDate": "2023-01-01",
   "Paragraph": "B16",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=12&code=ifrs-tx-2023-en-r&anchor=para_B16&doctype=Appendix&subtype=B",
   "URIDate": "2023-03-23"
  },
  "r97": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "13",
   "IssueDate": "2023-01-01",
   "Paragraph": "93",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=13&code=ifrs-tx-2023-en-r&anchor=para_93_a&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r98": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "13",
   "IssueDate": "2023-01-01",
   "Paragraph": "93",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=13&code=ifrs-tx-2023-en-r&anchor=para_93_b&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r99": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "13",
   "IssueDate": "2023-01-01",
   "Paragraph": "93",
   "Subparagraph": "d",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=13&code=ifrs-tx-2023-en-r&anchor=para_93_d&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r100": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "13",
   "IssueDate": "2023-01-01",
   "Paragraph": "93",
   "Subparagraph": "e",
   "Clause": "i",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=13&code=ifrs-tx-2023-en-r&anchor=para_93_e_i&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r101": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "13",
   "IssueDate": "2023-01-01",
   "Paragraph": "93",
   "Subparagraph": "e",
   "Clause": "iii",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=13&code=ifrs-tx-2023-en-r&anchor=para_93_e_iii&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r102": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "13",
   "IssueDate": "2023-01-01",
   "Paragraph": "93",
   "Subparagraph": "e",
   "Clause": "iv",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=13&code=ifrs-tx-2023-en-r&anchor=para_93_e_iv&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r103": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "13",
   "IssueDate": "2023-01-01",
   "Paragraph": "93",
   "Subparagraph": "e",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=13&code=ifrs-tx-2023-en-r&anchor=para_93_e&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r104": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "13",
   "IssueDate": "2023-01-01",
   "Paragraph": "93",
   "Subparagraph": "f",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=13&code=ifrs-tx-2023-en-r&anchor=para_93_f&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r105": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "13",
   "IssueDate": "2023-01-01",
   "Paragraph": "93",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=13&code=ifrs-tx-2023-en-r&anchor=para_93&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r106": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "13",
   "IssueDate": "2023-01-01",
   "Paragraph": "97",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=13&code=ifrs-tx-2023-en-r&anchor=para_97&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r107": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "13",
   "IssueDate": "2023-01-01",
   "Section": "Disclosure",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=13&code=ifrs-tx-2023-en-r&doctype=Standard&dita_xref=IFRS13_g91-99_TI",
   "URIDate": "2023-03-23"
  },
  "r108": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "14",
   "IssueDate": "2023-01-01",
   "Paragraph": "33",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=14&code=ifrs-tx-2023-en-r&anchor=para_33_b&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r109": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "15",
   "IssueDate": "2023-01-01",
   "Paragraph": "105",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=15&code=ifrs-tx-2023-en-r&anchor=para_105&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r110": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "15",
   "IssueDate": "2023-01-01",
   "Paragraph": "114",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=15&code=ifrs-tx-2023-en-r&anchor=para_114&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r111": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "15",
   "IssueDate": "2023-01-01",
   "Paragraph": "115",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=15&code=ifrs-tx-2023-en-r&anchor=para_115&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r112": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "15",
   "IssueDate": "2023-01-01",
   "Paragraph": "116",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=15&code=ifrs-tx-2023-en-r&anchor=para_116_a&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r113": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "15",
   "IssueDate": "2023-01-01",
   "Paragraph": "120",
   "Subparagraph": "b",
   "Clause": "i",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=15&code=ifrs-tx-2023-en-r&anchor=para_120_b_i&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r114": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "16",
   "IssueDate": "2023-01-01",
   "Paragraph": "47",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=16&code=ifrs-tx-2023-en-r&anchor=para_47_b&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r115": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "16",
   "IssueDate": "2023-01-01",
   "Paragraph": "53",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=16&code=ifrs-tx-2023-en-r&anchor=para_53_b&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r116": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "16",
   "IssueDate": "2023-01-01",
   "Paragraph": "94",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=16&code=ifrs-tx-2023-en-r&anchor=para_94&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r117": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "16",
   "IssueDate": "2023-01-01",
   "Paragraph": "97",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=16&code=ifrs-tx-2023-en-r&anchor=para_97&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r118": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "17",
   "IssueDate": "2023-01-01",
   "Paragraph": "109",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=17&code=ifrs-tx-2023-en-r&anchor=para_109&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r119": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "17",
   "IssueDate": "2023-01-01",
   "Paragraph": "109A",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=17&code=ifrs-tx-2023-en-r&anchor=para_109A&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r120": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "17",
   "IssueDate": "2023-01-01",
   "Paragraph": "120",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=17&code=ifrs-tx-2023-en-r&anchor=para_120&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r121": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "17",
   "IssueDate": "2023-01-01",
   "Paragraph": "124",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=17&code=ifrs-tx-2023-en-r&anchor=para_124&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r122": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "17",
   "IssueDate": "2023-01-01",
   "Paragraph": "125",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=17&code=ifrs-tx-2023-en-r&anchor=para_125&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r123": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "17",
   "IssueDate": "2023-01-01",
   "Paragraph": "127",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=17&code=ifrs-tx-2023-en-r&anchor=para_127&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r124": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "17",
   "IssueDate": "2023-01-01",
   "Paragraph": "128",
   "Subparagraph": "a",
   "Clause": "ii",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=17&code=ifrs-tx-2023-en-r&anchor=para_128_a_ii&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r125": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "17",
   "IssueDate": "2023-01-01",
   "Paragraph": "128",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=17&code=ifrs-tx-2023-en-r&anchor=para_128_a&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r126": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "17",
   "IssueDate": "2023-01-01",
   "Paragraph": "130",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=17&code=ifrs-tx-2023-en-r&anchor=para_130&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r127": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "17",
   "IssueDate": "2023-01-01",
   "Paragraph": "132",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=17&code=ifrs-tx-2023-en-r&anchor=para_132_b&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r128": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "2",
   "IssueDate": "2023-01-01",
   "Paragraph": "45",
   "Subparagraph": "d",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=2&code=ifrs-tx-2023-en-r&anchor=para_45_d&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r129": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "3",
   "IssueDate": "2023-01-01",
   "Paragraph": "B67",
   "Subparagraph": "d",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=3&code=ifrs-tx-2023-en-r&anchor=para_B67_d&doctype=Appendix&subtype=B",
   "URIDate": "2023-03-23"
  },
  "r130": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "5",
   "IssueDate": "2023-01-01",
   "Paragraph": "33",
   "Subparagraph": "b",
   "Clause": "i",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=5&code=ifrs-tx-2023-en-r&anchor=para_33_b_i&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r131": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "12B",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_12B_a&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r132": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "12B",
   "Subparagraph": "c",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_12B_c&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r133": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "12B",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_12B&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r134": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "12D",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_12D_a&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r135": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "13C",
   "Subparagraph": "c",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_13C_c&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r136": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "13C",
   "Subparagraph": "d",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_13C_d&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r137": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "13C",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_13C&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r138": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "15",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_15_a&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r139": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "20",
   "Subparagraph": "a",
   "Clause": "viii",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_20_a_viii&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r140": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "20",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_20_b&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r141": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "21C",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_21C&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r142": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "23B",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_23B_a&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r143": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "25",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_25&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r144": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "28",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_28_b&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r145": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "33",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_33&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r146": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "34",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_34&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r147": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "35H",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_35H_a&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r148": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "35H",
   "Subparagraph": "b",
   "Clause": "ii",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_35H_b_ii&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r149": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "35H",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_35H_b&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r150": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "35H",
   "Subparagraph": "c",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_35H_c&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r151": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "35H",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_35H&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r152": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "35I",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_35I&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r153": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "35K",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_35K&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r154": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "35M",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_35M_a&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r155": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "35M",
   "Subparagraph": "b",
   "Clause": "ii",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_35M_b_ii&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r156": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "35M",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_35M_b&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r157": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "35M",
   "Subparagraph": "c",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_35M_c&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r158": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "35M",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_35M&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r159": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "36",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_36&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r160": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "42E",
   "Subparagraph": "e",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_42E_e&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r161": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "8",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_8_a&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r162": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "8",
   "Subparagraph": "e",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_8_e&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r163": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "8",
   "Subparagraph": "f",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_8_f&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r164": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "8",
   "Subparagraph": "g",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_8_g&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r165": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "8",
   "Subparagraph": "h",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_8_h&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r166": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "8",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_8&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r167": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "B2",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_B2_a&doctype=Appendix&subtype=B",
   "URIDate": "2023-03-23"
  },
  "r168": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "B51",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_B51&doctype=Appendix&subtype=B",
   "URIDate": "2023-03-23"
  },
  "r169": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "B52",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_B52&doctype=Appendix&subtype=B",
   "URIDate": "2023-03-23"
  },
  "r170": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "B8E",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_B8E&doctype=Appendix&subtype=B",
   "URIDate": "2023-03-23"
  },
  "r171": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Section": "Defined terms",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&doctype=Appendix&subtype=A&dita_xref=IFRS07_APPA_TI",
   "URIDate": "2023-03-23"
  },
  "r172": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Section": "Offsetting financial assets and financial liabilities",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&doctype=Standard&dita_xref=IFRS07_g13A-13F_TI",
   "URIDate": "2023-03-23"
  },
  "r173": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2023-01-01",
   "Paragraph": "23",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2023-en-r&anchor=para_23_a&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r174": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2023-01-01",
   "Paragraph": "23",
   "Subparagraph": "g",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2023-en-r&anchor=para_23_g&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r175": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2023-01-01",
   "Paragraph": "23",
   "Subparagraph": "h",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2023-en-r&anchor=para_23_h&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r176": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2023-01-01",
   "Paragraph": "23",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2023-en-r&anchor=para_23&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r177": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2023-01-01",
   "Paragraph": "24",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2023-en-r&anchor=para_24_a&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r178": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2023-01-01",
   "Paragraph": "28",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2023-en-r&anchor=para_28_a&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r179": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2023-01-01",
   "Paragraph": "28",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2023-en-r&anchor=para_28_b&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r180": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2023-01-01",
   "Paragraph": "28",
   "Subparagraph": "c",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2023-en-r&anchor=para_28_c&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r181": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2023-01-01",
   "Paragraph": "28",
   "Subparagraph": "d",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2023-en-r&anchor=para_28_d&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r182": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2023-01-01",
   "Paragraph": "28",
   "Subparagraph": "e",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2023-en-r&anchor=para_28_e&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r183": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2023-01-01",
   "Paragraph": "28",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2023-en-r&anchor=para_28&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r184": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2023-01-01",
   "Paragraph": "32",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2023-en-r&anchor=para_32&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r185": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2023-01-01",
   "Paragraph": "33",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2023-en-r&anchor=para_33_a&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r186": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2023-01-01",
   "Paragraph": "33",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2023-en-r&anchor=para_33&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r187": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2023-01-01",
   "Paragraph": "34",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2023-en-r&anchor=para_34&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r188": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2023-01-01",
   "Section": "Disclosure",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2023-en-r&doctype=Standard&dita_xref=IFRS08_g20-24_TI",
   "URIDate": "2023-03-23"
  },
  "r189": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "9",
   "IssueDate": "2023-01-01",
   "Paragraph": "6.5.11",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=9&code=ifrs-tx-2023-en-r&anchor=para_6.5.11&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r190": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "9",
   "IssueDate": "2023-01-01",
   "Paragraph": "6.5.13",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=9&code=ifrs-tx-2023-en-r&anchor=para_6.5.13_a&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r191": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Name": "IFRS",
   "Number": "9",
   "IssueDate": "2023-01-01",
   "Paragraph": "6.5.14",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=9&code=ifrs-tx-2023-en-r&anchor=para_6.5.14&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r192": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Note": "Expired 2023-01-01",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "20",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2017-en-b&anchor=para_20_b&doctype=Standard&book=b",
   "URIDate": "2023-03-23"
  },
  "r193": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Note": "Expired 2023-01-01",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "37",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2017-en-b&anchor=para_37&doctype=Standard&book=b",
   "URIDate": "2023-03-23"
  },
  "r194": {
   "role": "http://www.xbrl.org/2003/role/disclosureRef",
   "Note": "Expired 2023-01-01",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "8",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2017-en-b&anchor=para_8_a&doctype=Standard&book=b",
   "URIDate": "2023-03-23"
  },
  "r195": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "102",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_102&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r196": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "103",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_103&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r197": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "108",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_108&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r198": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "78",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_78_b&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r199": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "78",
   "Subparagraph": "e",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_78_e&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r200": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "82A",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_82A&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r201": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "IG6",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_IG6&doctype=Implementation%20Guidance",
   "URIDate": "2023-03-23"
  },
  "r202": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "19",
   "IssueDate": "2023-01-01",
   "Paragraph": "138",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=19&code=ifrs-tx-2023-en-r&anchor=para_138_a&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r203": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "19",
   "IssueDate": "2023-01-01",
   "Paragraph": "138",
   "Subparagraph": "d",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=19&code=ifrs-tx-2023-en-r&anchor=para_138_d&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r204": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "19",
   "IssueDate": "2023-01-01",
   "Paragraph": "147",
   "Subparagraph": "c",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=19&code=ifrs-tx-2023-en-r&anchor=para_147_c&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r205": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "37",
   "IssueDate": "2023-01-01",
   "Paragraph": "70",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=37&code=ifrs-tx-2023-en-r&anchor=para_70&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r206": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "37",
   "IssueDate": "2023-01-01",
   "Paragraph": "87",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=37&code=ifrs-tx-2023-en-r&anchor=para_87&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r207": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IAS",
   "Number": "37",
   "IssueDate": "2023-01-01",
   "Section": "Example 10 A court case",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=37&code=ifrs-tx-2023-en-r&doctype=Illustrative%20Examples&dita_xref=IAS37_IE_C_ex10_TI",
   "URIDate": "2023-03-23"
  },
  "r208": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "12",
   "IssueDate": "2023-01-01",
   "Paragraph": "B10",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=12&code=ifrs-tx-2023-en-r&anchor=para_B10_b&doctype=Appendix&subtype=B",
   "URIDate": "2023-03-23"
  },
  "r209": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "12",
   "IssueDate": "2023-01-01",
   "Paragraph": "B23",
   "Subparagraph": "c",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=12&code=ifrs-tx-2023-en-r&anchor=para_B23_c&doctype=Appendix&subtype=B",
   "URIDate": "2023-03-23"
  },
  "r210": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "13",
   "IssueDate": "2023-01-01",
   "Paragraph": "93",
   "Subparagraph": "d",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=13&code=ifrs-tx-2023-en-r&anchor=para_93_d&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r211": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "13",
   "IssueDate": "2023-01-01",
   "Paragraph": "94",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=13&code=ifrs-tx-2023-en-r&anchor=para_94&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r212": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "13",
   "IssueDate": "2023-01-01",
   "Paragraph": "B11",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=13&code=ifrs-tx-2023-en-r&anchor=para_B11_a&doctype=Appendix&subtype=B",
   "URIDate": "2023-03-23"
  },
  "r213": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "13",
   "IssueDate": "2023-01-01",
   "Paragraph": "B11",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=13&code=ifrs-tx-2023-en-r&anchor=para_B11_b&doctype=Appendix&subtype=B",
   "URIDate": "2023-03-23"
  },
  "r214": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "13",
   "IssueDate": "2023-01-01",
   "Paragraph": "B36",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=13&code=ifrs-tx-2023-en-r&anchor=para_B36_b&doctype=Appendix&subtype=B",
   "URIDate": "2023-03-23"
  },
  "r215": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "13",
   "IssueDate": "2023-01-01",
   "Paragraph": "B5",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=13&code=ifrs-tx-2023-en-r&anchor=para_B5&doctype=Appendix&subtype=B",
   "URIDate": "2023-03-23"
  },
  "r216": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "13",
   "IssueDate": "2023-01-01",
   "Paragraph": "B6",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=13&code=ifrs-tx-2023-en-r&anchor=para_B6&doctype=Appendix&subtype=B",
   "URIDate": "2023-03-23"
  },
  "r217": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "13",
   "IssueDate": "2023-01-01",
   "Paragraph": "IE60",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=13&code=ifrs-tx-2023-en-r&anchor=para_IE60&doctype=Illustrative%20Examples",
   "URIDate": "2023-03-23"
  },
  "r218": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "13",
   "IssueDate": "2023-01-01",
   "Paragraph": "IE63",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=13&code=ifrs-tx-2023-en-r&anchor=para_IE63&doctype=Illustrative%20Examples",
   "URIDate": "2023-03-23"
  },
  "r219": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "15",
   "IssueDate": "2023-01-01",
   "Paragraph": "B89",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=15&code=ifrs-tx-2023-en-r&anchor=para_B89_b&doctype=Appendix&subtype=B",
   "URIDate": "2023-03-23"
  },
  "r220": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "15",
   "IssueDate": "2023-01-01",
   "Paragraph": "B89",
   "Subparagraph": "f",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=15&code=ifrs-tx-2023-en-r&anchor=para_B89_f&doctype=Appendix&subtype=B",
   "URIDate": "2023-03-23"
  },
  "r221": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "17",
   "IssueDate": "2023-01-01",
   "Paragraph": "113",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=17&code=ifrs-tx-2023-en-r&anchor=para_113_b&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r222": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "17",
   "IssueDate": "2023-01-01",
   "Paragraph": "96",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=17&code=ifrs-tx-2023-en-r&anchor=para_96_b&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r223": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "17",
   "IssueDate": "2023-01-01",
   "Paragraph": "96",
   "Subparagraph": "c",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=17&code=ifrs-tx-2023-en-r&anchor=para_96_c&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r224": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "13C",
   "Subparagraph": "d",
   "Clause": "i",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_13C_d_i&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r225": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "13C",
   "Subparagraph": "d",
   "Clause": "ii",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_13C_d_ii&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r226": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "28",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_28_b&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r227": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "32",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_32&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r228": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "35N",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_35N&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r229": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "40",
   "Subparagraph": "a",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_40_a&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r230": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "6",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_6&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r231": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "B11",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_B11&doctype=Appendix&subtype=B",
   "URIDate": "2023-03-23"
  },
  "r232": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "B33",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_B33&doctype=Appendix&subtype=B",
   "URIDate": "2023-03-23"
  },
  "r233": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "B35",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_B35&doctype=Appendix&subtype=B",
   "URIDate": "2023-03-23"
  },
  "r234": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "IG14",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_IG14&doctype=Implementation%20Guidance",
   "URIDate": "2023-03-23"
  },
  "r235": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "IG20B",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_IG20B&doctype=Implementation%20Guidance",
   "URIDate": "2023-03-23"
  },
  "r236": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "IG20C",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_IG20C&doctype=Implementation%20Guidance",
   "URIDate": "2023-03-23"
  },
  "r237": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "IG20D",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_IG20D&doctype=Implementation%20Guidance",
   "URIDate": "2023-03-23"
  },
  "r238": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "IG31A",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_IG31A&doctype=Implementation%20Guidance",
   "URIDate": "2023-03-23"
  },
  "r239": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "IG32",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_IG32&doctype=Implementation%20Guidance",
   "URIDate": "2023-03-23"
  },
  "r240": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "IG40B",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_IG40B&doctype=Implementation%20Guidance",
   "URIDate": "2023-03-23"
  },
  "r241": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "IG40D",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_IG40D&doctype=Implementation%20Guidance",
   "URIDate": "2023-03-23"
  },
  "r242": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2023-01-01",
   "Paragraph": "23",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2023-en-r&anchor=para_23&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r243": {
   "role": "http://www.xbrl.org/2003/role/exampleRef",
   "Name": "IFRS",
   "Number": "8",
   "IssueDate": "2023-01-01",
   "Paragraph": "28",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=8&code=ifrs-tx-2023-en-r&anchor=para_28_b&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r244": {
   "role": "http://www.xbrl.org/2003/role/presentationRef",
   "Publisher": "SEC",
   "Name": "Exchange Act",
   "Number": "240",
   "Section": "12",
   "Subsection": "b-2"
  },
  "r245": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "10",
   "Subparagraph": "e",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_10_e&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r246": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "106",
   "Subparagraph": "d",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_106_d&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r247": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "112",
   "Subparagraph": "c",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_112_c&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r248": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "117",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_117&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r249": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "55",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_55&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r250": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "78",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_78_b&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r251": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "78",
   "Subparagraph": "e",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_78_e&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r252": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "1",
   "IssueDate": "2023-01-01",
   "Paragraph": "85",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=1&code=ifrs-tx-2023-en-r&anchor=para_85&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r253": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "12",
   "IssueDate": "2023-01-01",
   "Paragraph": "81",
   "Subparagraph": "g",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=12&code=ifrs-tx-2023-en-r&anchor=para_81_g&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r254": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "19",
   "IssueDate": "2023-01-01",
   "Paragraph": "135",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=19&code=ifrs-tx-2023-en-r&anchor=para_135_b&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r255": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "19",
   "IssueDate": "2023-01-01",
   "Paragraph": "5",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=19&code=ifrs-tx-2023-en-r&anchor=para_5&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r256": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "19",
   "IssueDate": "2023-01-01",
   "Paragraph": "9",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=19&code=ifrs-tx-2023-en-r&anchor=para_9&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r257": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "17",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2023-en-r&anchor=para_17&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r258": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "20",
   "Subparagraph": "b",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2023-en-r&anchor=para_20_b&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r259": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "20",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2023-en-r&anchor=para_20&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r260": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IAS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "45",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IAS&num=7&code=ifrs-tx-2023-en-r&anchor=para_45&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r261": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IFRS",
   "Number": "13",
   "IssueDate": "2023-01-01",
   "Paragraph": "93",
   "Subparagraph": "c",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=13&code=ifrs-tx-2023-en-r&anchor=para_93_c&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r262": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IFRS",
   "Number": "13",
   "IssueDate": "2023-01-01",
   "Paragraph": "93",
   "Subparagraph": "d",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=13&code=ifrs-tx-2023-en-r&anchor=para_93_d&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r263": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IFRS",
   "Number": "13",
   "IssueDate": "2023-01-01",
   "Paragraph": "93",
   "Subparagraph": "h",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=13&code=ifrs-tx-2023-en-r&anchor=para_93_h&doctype=Standard",
   "URIDate": "2023-03-23"
  },
  "r264": {
   "role": "http://www.xbrl.org/2009/role/commonPracticeRef",
   "Name": "IFRS",
   "Number": "7",
   "IssueDate": "2023-01-01",
   "Paragraph": "7",
   "URI": "https://taxonomy.ifrs.org/xifrs-link?type=IFRS&num=7&code=ifrs-tx-2023-en-r&anchor=para_7&doctype=Standard",
   "URIDate": "2023-03-23"
  }
 }
}
