<?xml version="1.0" encoding="us-ascii" standalone="yes"?>
<!--Created by 2H Software, Powered by IRIS Carbon, Unique Code 6808131f2eea2b2b44edc7c7, Generated At Tue, 22 Apr 2025 22:10:49 GMT-->
<link:linkbase xmlns:xbrldt="http://xbrl.org/2005/xbrldt" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xl="http://www.xbrl.org/2003/XLink" xmlns:link="http://www.xbrl.org/2003/linkbase" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xlink="http://www.w3.org/1999/xlink" xmlns:xbrli="http://www.xbrl.org/2003/instance" xsi:schemaLocation="http://www.xbrl.org/2003/linkbase http://www.xbrl.org/2003/xbrl-linkbase-2003-12-31.xsd">
  <link:roleRef roleURI="http://www.ultrapar.com/role/Consolidatedstatementsofcomprehensiveincome" xlink:type="simple" xlink:href="ugp-20241231.xsd#Consolidatedstatementsofcomprehensiveincome" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/EquityDividendsAndAllocationOfNetIncomeDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#EquityDividendsAndAllocationOfNetIncomeDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/IncomeAndSocialContributionTaxesDeferredTaxesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#IncomeAndSocialContributionTaxesDeferredTaxesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/SegmentInformationAssetsBySegmentsDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#SegmentInformationAssetsBySegmentsDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/FinancialInstrumentsScheduleofleverageratioDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#FinancialInstrumentsScheduleofleverageratioDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/FinancialInstrumentsAssetsandliabilitiesinforeigncurrenciesDetailCalc2" xlink:type="simple" xlink:href="ugp-20241231.xsd#FinancialInstrumentsAssetsandliabilitiesinforeigncurrenciesDetailCalc2" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/ProvisionsandcontingentliabilitiesBreakdownofprovisionsbynatureDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#ProvisionsandcontingentliabilitiesBreakdownofprovisionsbynatureDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/EmployeebenefitsandprivatepensionplanPostemploymentBenefitsDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#EmployeebenefitsandprivatepensionplanPostemploymentBenefitsDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RelatedPartiesRestrictedStockProgramDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#RelatedPartiesRestrictedStockProgramDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RecoverabletaxesSummaryofRecoverableTaxesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#RecoverabletaxesSummaryofRecoverableTaxesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/TradeReceivablesandResellerFinancingCompositionofResellerFinancingDetailCalc2" xlink:type="simple" xlink:href="ugp-20241231.xsd#TradeReceivablesandResellerFinancingCompositionofResellerFinancingDetailCalc2" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/TradereceivablesresellerfinancingandotherreceivablesCompositionofResellerFinancingDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#TradereceivablesresellerfinancingandotherreceivablesCompositionofResellerFinancingDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/TradereceivablesresellerfinancingandotherreceivablesTradereceivablesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#TradereceivablesresellerfinancingandotherreceivablesTradereceivablesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/CashandCashEquivalentsandFinancialInvestmentsFinancialinvestmentsDetailCalc2" xlink:type="simple" xlink:href="ugp-20241231.xsd#CashandCashEquivalentsandFinancialInvestmentsFinancialinvestmentsDetailCalc2" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/Consolidatedstatementsofchangesinequity" xlink:type="simple" xlink:href="ugp-20241231.xsd#Consolidatedstatementsofchangesinequity" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/ConsolidatedstatementsofcomprehensiveincomeCalc2" xlink:type="simple" xlink:href="ugp-20241231.xsd#ConsolidatedstatementsofcomprehensiveincomeCalc2" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/ConsolidatedstatementsofincomeCalc2" xlink:type="simple" xlink:href="ugp-20241231.xsd#ConsolidatedstatementsofincomeCalc2" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/Consolidatedstatementsofincome" xlink:type="simple" xlink:href="ugp-20241231.xsd#Consolidatedstatementsofincome" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/FinancialInstrumentsAssetsandliabilitiesexposedtoforeigncurrencytranslatedtoReaisandorexposedtofloatinginterestratesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#FinancialInstrumentsAssetsandliabilitiesexposedtoforeigncurrencytranslatedtoReaisandorexposedtofloatinginterestratesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/Consolidatedstatementsofcashflowsindirectmethod" xlink:type="simple" xlink:href="ugp-20241231.xsd#Consolidatedstatementsofcashflowsindirectmethod" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/SegmentinformationFinancialInformationofSegmentsDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#SegmentinformationFinancialInformationofSegmentsDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/FinancialresultFinancialresultDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#FinancialresultFinancialresultDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/CostsexpensesandotheroperatingresultsbynatureCostsandexpensesbynatureDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#CostsexpensesandotheroperatingresultsbynatureCostsandexpensesbynatureDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/AcquisitionofInterestandControlScheduleoftransactionamountsforacquiringaninterestDetails" xlink:type="simple" xlink:href="ugp-20241231.xsd#AcquisitionofInterestandControlScheduleoftransactionamountsforacquiringaninterestDetails" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/AcquisitionofInterestandControlScheduleoftheprovisionalbalancesofassetsacquiredandliabilitiesassumedontheacquisitiondateDetails" xlink:type="simple" xlink:href="ugp-20241231.xsd#AcquisitionofInterestandControlScheduleoftheprovisionalbalancesofassetsacquiredandliabilitiesassumedontheacquisitiondateDetails" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/IncomeAndSocialContributionTaxesSummaryOfReconciliationOfTaxesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#IncomeAndSocialContributionTaxesSummaryOfReconciliationOfTaxesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/ConsolidatedstatementsofcashflowsindirectmethodCalc2" xlink:type="simple" xlink:href="ugp-20241231.xsd#ConsolidatedstatementsofcashflowsindirectmethodCalc2" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/DiscontinuedoperationsDetails" xlink:type="simple" xlink:href="ugp-20241231.xsd#DiscontinuedoperationsDetails" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/FinancialInstrumentsSensitivityanalysiswithdevaluationoftheRealandinterestrateincreaseDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#FinancialInstrumentsSensitivityanalysiswithdevaluationoftheRealandinterestrateincreaseDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/EarningspershareBasicandDilutedEarningsperShareDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#EarningspershareBasicandDilutedEarningsperShareDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/CostsandexpensesbynatureCostsandexpensesbynatureDetailCalc2" xlink:type="simple" xlink:href="ugp-20241231.xsd#CostsandexpensesbynatureCostsandexpensesbynatureDetailCalc2" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/EquityDividendsandAllocationofNetIncomeDetailCalc2" xlink:type="simple" xlink:href="ugp-20241231.xsd#EquityDividendsandAllocationofNetIncomeDetailCalc2" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/LoansfinancingdebenturesandderivativefinancialinstrumentsSummaryofCompostionofloansDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#LoansfinancingdebenturesandderivativefinancialinstrumentsSummaryofCompostionofloansDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/IntangibleassetsTransfertopropertyplantandequipmentDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#IntangibleassetsTransfertopropertyplantandequipmentDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RelatedPartiesSummaryOfExpensesForCompensationOfItsKeyExecutivesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#RelatedPartiesSummaryOfExpensesForCompensationOfItsKeyExecutivesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/CashandcashequivalentsfinancialinvestmentsderivativefinancialinstrumentsandotherfinancialassetsFinancialinvestmentsDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#CashandcashequivalentsfinancialinvestmentsderivativefinancialinstrumentsandotherfinancialassetsFinancialinvestmentsDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/CashandcashequivalentsfinancialinvestmentsderivativefinancialinstrumentsandotherfinancialassetsCashandcashequivalentsDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#CashandcashequivalentsfinancialinvestmentsderivativefinancialinstrumentsandotherfinancialassetsCashandcashequivalentsDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/Consolidatedstatementsoffinancialposition" xlink:type="simple" xlink:href="ugp-20241231.xsd#Consolidatedstatementsoffinancialposition" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/CoverPage" xlink:type="simple" xlink:href="ugp-20241231.xsd#CoverPage" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/ConsolidatedstatementsofchangesinequityParenthetical" xlink:type="simple" xlink:href="ugp-20241231.xsd#ConsolidatedstatementsofchangesinequityParenthetical" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/Operations" xlink:type="simple" xlink:href="ugp-20241231.xsd#Operations" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/Basisofpreparationandpresentationofconsolidatedfinancialstatements" xlink:type="simple" xlink:href="ugp-20241231.xsd#Basisofpreparationandpresentationofconsolidatedfinancialstatements" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/Newaccountingpoliciesandchangesinaccountingpolicies" xlink:type="simple" xlink:href="ugp-20241231.xsd#Newaccountingpoliciesandchangesinaccountingpolicies" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/PrinciplesOfConsolidationAndInvestmentsInSubsidiaries" xlink:type="simple" xlink:href="ugp-20241231.xsd#PrinciplesOfConsolidationAndInvestmentsInSubsidiaries" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/Cashandcashequivalentsfinancialinvestmentsderivativefinancialinstrumentsandotherfinancialassets" xlink:type="simple" xlink:href="ugp-20241231.xsd#Cashandcashequivalentsfinancialinvestmentsderivativefinancialinstrumentsandotherfinancialassets" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/Tradereceivablesresellerfinancingandotherreceivables" xlink:type="simple" xlink:href="ugp-20241231.xsd#Tradereceivablesresellerfinancingandotherreceivables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/Inventories" xlink:type="simple" xlink:href="ugp-20241231.xsd#Inventories" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/Recoverabletaxes" xlink:type="simple" xlink:href="ugp-20241231.xsd#Recoverabletaxes" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RelatedParties" xlink:type="simple" xlink:href="ugp-20241231.xsd#RelatedParties" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/IncomeAndSocialContributionTaxes" xlink:type="simple" xlink:href="ugp-20241231.xsd#IncomeAndSocialContributionTaxes" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/PrepaidExpenses" xlink:type="simple" xlink:href="ugp-20241231.xsd#PrepaidExpenses" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/Contractualassetswithcustomersexclusivityrights" xlink:type="simple" xlink:href="ugp-20241231.xsd#Contractualassetswithcustomersexclusivityrights" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/Investmentsinsubsidiariesjointventuresandassociates" xlink:type="simple" xlink:href="ugp-20241231.xsd#Investmentsinsubsidiariesjointventuresandassociates" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/Rightofuseassetsandleasespayable" xlink:type="simple" xlink:href="ugp-20241231.xsd#Rightofuseassetsandleasespayable" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/Propertyplantandequipment" xlink:type="simple" xlink:href="ugp-20241231.xsd#Propertyplantandequipment" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/Intangibleassets" xlink:type="simple" xlink:href="ugp-20241231.xsd#Intangibleassets" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/Loansfinancingdebenturesandderivativefinancialinstruments" xlink:type="simple" xlink:href="ugp-20241231.xsd#Loansfinancingdebenturesandderivativefinancialinstruments" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/Tradepayables" xlink:type="simple" xlink:href="ugp-20241231.xsd#Tradepayables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/Salariesandrelatedcharges" xlink:type="simple" xlink:href="ugp-20241231.xsd#Salariesandrelatedcharges" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/TaxesPayable" xlink:type="simple" xlink:href="ugp-20241231.xsd#TaxesPayable" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/Employeebenefitsandprivatepensionplan" xlink:type="simple" xlink:href="ugp-20241231.xsd#Employeebenefitsandprivatepensionplan" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/Provisionforassetretirementobligation" xlink:type="simple" xlink:href="ugp-20241231.xsd#Provisionforassetretirementobligation" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/Provisionsandcontingentliabilities" xlink:type="simple" xlink:href="ugp-20241231.xsd#Provisionsandcontingentliabilities" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/DeferredRevenue" xlink:type="simple" xlink:href="ugp-20241231.xsd#DeferredRevenue" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/SubscriptionWarrantsIndemnification" xlink:type="simple" xlink:href="ugp-20241231.xsd#SubscriptionWarrantsIndemnification" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/Equity" xlink:type="simple" xlink:href="ugp-20241231.xsd#Equity" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/Costsexpensesandotheroperatingresultsbynature" xlink:type="simple" xlink:href="ugp-20241231.xsd#Costsexpensesandotheroperatingresultsbynature" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/Gainlossondisposalofpropertyplantandequipmentandintangibleassets" xlink:type="simple" xlink:href="ugp-20241231.xsd#Gainlossondisposalofpropertyplantandequipmentandintangibleassets" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/Otheroperatingincomenet" xlink:type="simple" xlink:href="ugp-20241231.xsd#Otheroperatingincomenet" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/Financialresult" xlink:type="simple" xlink:href="ugp-20241231.xsd#Financialresult" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/Earningspershare" xlink:type="simple" xlink:href="ugp-20241231.xsd#Earningspershare" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/Segmentinformation" xlink:type="simple" xlink:href="ugp-20241231.xsd#Segmentinformation" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/FinancialInstruments" xlink:type="simple" xlink:href="ugp-20241231.xsd#FinancialInstruments" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/Commitments" xlink:type="simple" xlink:href="ugp-20241231.xsd#Commitments" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/AcquisitionofInterestandControl" xlink:type="simple" xlink:href="ugp-20241231.xsd#AcquisitionofInterestandControl" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/Discontinuedoperations" xlink:type="simple" xlink:href="ugp-20241231.xsd#Discontinuedoperations" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/Eventsafterthereportingperiod" xlink:type="simple" xlink:href="ugp-20241231.xsd#Eventsafterthereportingperiod" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/BasisofpreparationandpresentationofconsolidatedfinancialstatementsPolicies" xlink:type="simple" xlink:href="ugp-20241231.xsd#BasisofpreparationandpresentationofconsolidatedfinancialstatementsPolicies" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/OperationsTables" xlink:type="simple" xlink:href="ugp-20241231.xsd#OperationsTables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/PresentationOfFinancialStatementsAndSummaryOfSignificantAccountingPoliciesTables" xlink:type="simple" xlink:href="ugp-20241231.xsd#PresentationOfFinancialStatementsAndSummaryOfSignificantAccountingPoliciesTables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/CashandcashequivalentsfinancialinvestmentsderivativefinancialinstrumentsandotherfinancialassetsTables" xlink:type="simple" xlink:href="ugp-20241231.xsd#CashandcashequivalentsfinancialinvestmentsderivativefinancialinstrumentsandotherfinancialassetsTables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/TradereceivablesresellerfinancingandotherreceivablesTables" xlink:type="simple" xlink:href="ugp-20241231.xsd#TradereceivablesresellerfinancingandotherreceivablesTables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/InventoriesTables" xlink:type="simple" xlink:href="ugp-20241231.xsd#InventoriesTables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RecoverabletaxesTables" xlink:type="simple" xlink:href="ugp-20241231.xsd#RecoverabletaxesTables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RelatedPartiesTables" xlink:type="simple" xlink:href="ugp-20241231.xsd#RelatedPartiesTables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/IncomeAndSocialContributionTaxesTables" xlink:type="simple" xlink:href="ugp-20241231.xsd#IncomeAndSocialContributionTaxesTables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/PrepaidExpensesTables" xlink:type="simple" xlink:href="ugp-20241231.xsd#PrepaidExpensesTables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/ContractualassetswithcustomersexclusivityrightsTables" xlink:type="simple" xlink:href="ugp-20241231.xsd#ContractualassetswithcustomersexclusivityrightsTables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/InvestmentsinsubsidiariesjointventuresandassociatesTables" xlink:type="simple" xlink:href="ugp-20241231.xsd#InvestmentsinsubsidiariesjointventuresandassociatesTables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RightofuseassetsandleasespayableTables" xlink:type="simple" xlink:href="ugp-20241231.xsd#RightofuseassetsandleasespayableTables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/PropertyPlantAndEquipmentTables" xlink:type="simple" xlink:href="ugp-20241231.xsd#PropertyPlantAndEquipmentTables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/IntangibleassetsTables" xlink:type="simple" xlink:href="ugp-20241231.xsd#IntangibleassetsTables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/LoansfinancingdebenturesandderivativefinancialinstrumentsTables" xlink:type="simple" xlink:href="ugp-20241231.xsd#LoansfinancingdebenturesandderivativefinancialinstrumentsTables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/TradePayablesTables" xlink:type="simple" xlink:href="ugp-20241231.xsd#TradePayablesTables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/SalariesandrelatedchargesTables" xlink:type="simple" xlink:href="ugp-20241231.xsd#SalariesandrelatedchargesTables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/TaxesPayableTables" xlink:type="simple" xlink:href="ugp-20241231.xsd#TaxesPayableTables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/EmployeebenefitsandprivatepensionplanTables" xlink:type="simple" xlink:href="ugp-20241231.xsd#EmployeebenefitsandprivatepensionplanTables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/ProvisionforassetretirementobligationTables" xlink:type="simple" xlink:href="ugp-20241231.xsd#ProvisionforassetretirementobligationTables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/ProvisionsandcontingentliabilitiesTables" xlink:type="simple" xlink:href="ugp-20241231.xsd#ProvisionsandcontingentliabilitiesTables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/DeferredRevenueTables" xlink:type="simple" xlink:href="ugp-20241231.xsd#DeferredRevenueTables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/EquityTables" xlink:type="simple" xlink:href="ugp-20241231.xsd#EquityTables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/CostsexpensesandotheroperatingresultsbynatureTables" xlink:type="simple" xlink:href="ugp-20241231.xsd#CostsexpensesandotheroperatingresultsbynatureTables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/OtheroperatingincomenetTables" xlink:type="simple" xlink:href="ugp-20241231.xsd#OtheroperatingincomenetTables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/FinancialresultTables" xlink:type="simple" xlink:href="ugp-20241231.xsd#FinancialresultTables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/EarningspershareTables" xlink:type="simple" xlink:href="ugp-20241231.xsd#EarningspershareTables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/SegmentinformationTables" xlink:type="simple" xlink:href="ugp-20241231.xsd#SegmentinformationTables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/FinancialInstrumentsTables" xlink:type="simple" xlink:href="ugp-20241231.xsd#FinancialInstrumentsTables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/CommitmentsTables" xlink:type="simple" xlink:href="ugp-20241231.xsd#CommitmentsTables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/AcquisitionofInterestandControlTables" xlink:type="simple" xlink:href="ugp-20241231.xsd#AcquisitionofInterestandControlTables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/DiscontinuedoperationsTables" xlink:type="simple" xlink:href="ugp-20241231.xsd#DiscontinuedoperationsTables" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/OperationsDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#OperationsDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/OperationsOperationalimpactsDetailsTextuals" xlink:type="simple" xlink:href="ugp-20241231.xsd#OperationsOperationalimpactsDetailsTextuals" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/OperationsMainrisksandassociatedmeasuresDetailsTextuals" xlink:type="simple" xlink:href="ugp-20241231.xsd#OperationsMainrisksandassociatedmeasuresDetailsTextuals" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/BasisofpreparationandpresentationoftheconsolidatedfinancialstatementsandsignificantaccountingpoliciesAdditionalInformationDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#BasisofpreparationandpresentationoftheconsolidatedfinancialstatementsandsignificantaccountingpoliciesAdditionalInformationDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/CashandcashequivalentsfinancialinvestmentsandderivativefinancialinstrumentsAdditionalInformationDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#CashandcashequivalentsfinancialinvestmentsandderivativefinancialinstrumentsAdditionalInformationDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/TradereceivablesresellerfinancingandotherreceivablesSummaryofMovementsintheAllowanceforLossAllowanceforExpectedCreditLossesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#TradereceivablesresellerfinancingandotherreceivablesSummaryofMovementsintheAllowanceforLossAllowanceforExpectedCreditLossesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/TradereceivablesresellerfinancingandotherreceivablesSummaryofofTradeReceivablesGrossofLossAllowanceforExpectedCreditLossesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#TradereceivablesresellerfinancingandotherreceivablesSummaryofofTradeReceivablesGrossofLossAllowanceforExpectedCreditLossesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/TradereceivablesresellerfinancingandotherreceivablessaleofsubsidiariesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#TradereceivablesresellerfinancingandotherreceivablessaleofsubsidiariesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/TradeReceivablesandResellerFinancingTradereceivablesDetailCalc2" xlink:type="simple" xlink:href="ugp-20241231.xsd#TradeReceivablesandResellerFinancingTradereceivablesDetailCalc2" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/TradereceivablesresellerfinancingandotherreceivablesBreakdownofLossAllowanceforExpectedCreditLossesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#TradereceivablesresellerfinancingandotherreceivablesBreakdownofLossAllowanceforExpectedCreditLossesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/TradereceivablesresellerfinancingandotherreceivablesBreakdownofResellerFinancingGrossofLossAllowanceforExpectedCreditLossesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#TradereceivablesresellerfinancingandotherreceivablesBreakdownofResellerFinancingGrossofLossAllowanceforExpectedCreditLossesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/TradereceivablesresellerfinancingandotherreceivablesAdditionalInformationDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#TradereceivablesresellerfinancingandotherreceivablesAdditionalInformationDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/InventoriesBreakdownofInventoriesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#InventoriesBreakdownofInventoriesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/InventoriesMovementsintheProvisionforinventoryLossesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#InventoriesMovementsintheProvisionforinventoryLossesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/InventoriesBreakdownofProvisionforLossesRelatedtoInventoriesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#InventoriesBreakdownofProvisionforLossesRelatedtoInventoriesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RecoverabletaxesScheduleofestimatedrecoveryofICMScreditsDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#RecoverabletaxesScheduleofestimatedrecoveryofICMScreditsDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RecoverabletaxesScheduleofestimatedrecoveryofPISandCOFINScreditsDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#RecoverabletaxesScheduleofestimatedrecoveryofPISandCOFINScreditsDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RecoverabletaxesAdditionalInformationDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#RecoverabletaxesAdditionalInformationDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RelatedPartiesSummaryOfSubsidiariesAndOtherRelatedPartiesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#RelatedPartiesSummaryOfSubsidiariesAndOtherRelatedPartiesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RelatedPartiesSummarizedChangesOfNumberOfRestrictedAndPerformanceSharesGrantedDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#RelatedPartiesSummarizedChangesOfNumberOfRestrictedAndPerformanceSharesGrantedDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RelatedPartiesAdditionalInformationDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#RelatedPartiesAdditionalInformationDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/IncomeAndSocialContributionTaxesSummaryOfChangesInBalancesOfDeferredTaxesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#IncomeAndSocialContributionTaxesSummaryOfChangesInBalancesOfDeferredTaxesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/IncomeAndSocialContributionTaxesSummaryOfDeferredIncomeAndSocialContributionTaxAssetsDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#IncomeAndSocialContributionTaxesSummaryOfDeferredIncomeAndSocialContributionTaxAssetsDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/IncomeAndSocialContributionTaxesAdditionalInformationDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#IncomeAndSocialContributionTaxesAdditionalInformationDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/ContractualassetswithcustomersexclusivityrightsSummaryofContractualAssetswithCustomersExclusiveRightsBalanceandChangesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#ContractualassetswithcustomersexclusivityrightsSummaryofContractualAssetswithCustomersExclusiveRightsBalanceandChangesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/InvestmentsinsubsidiariesjointventuresandassociatesSummaryofthepositionsofequityandincomelossfortheyearDetails" xlink:type="simple" xlink:href="ugp-20241231.xsd#InvestmentsinsubsidiariesjointventuresandassociatesSummaryofthepositionsofequityandincomelossfortheyearDetails" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/InvestmentsinsubsidiariesjointventuresandassociatesSummaryoffinancialpositionandincomeofsubsidiarieswhichhaverelevantnoncontrollinginterestsDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#InvestmentsinsubsidiariesjointventuresandassociatesSummaryoffinancialpositionandincomeofsubsidiarieswhichhaverelevantnoncontrollinginterestsDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/InvestmentsinsubsidiariesjointventuresandassociatesSummaryofstatementsoffinancialinformationofjointventuresandassociatesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#InvestmentsinsubsidiariesjointventuresandassociatesSummaryofstatementsoffinancialinformationofjointventuresandassociatesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/InvestmentsinsubsidiariesjointventuresandassociatesSummaryofbalancesandchangesininvestmentsinjointventuresandassociatesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#InvestmentsinsubsidiariesjointventuresandassociatesSummaryofbalancesandchangesininvestmentsinjointventuresandassociatesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/InvestmentsinsubsidiariesjointventuresandassociatesDetailsTextuals" xlink:type="simple" xlink:href="ugp-20241231.xsd#InvestmentsinsubsidiariesjointventuresandassociatesDetailsTextuals" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RightofuseassetsandleasespayableSummaryofInformationAboutRightofUseAssetsDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#RightofuseassetsandleasespayableSummaryofInformationAboutRightofUseAssetsDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RightofuseassetsandleasespayableSummaryofInformationAboutRightofUseAssetsDetailParenthetical" xlink:type="simple" xlink:href="ugp-20241231.xsd#RightofuseassetsandleasespayableSummaryofInformationAboutRightofUseAssetsDetailParenthetical" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RightofuseassetsandleasespayableSummaryofChangesinLeasePayablesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#RightofuseassetsandleasespayableSummaryofChangesinLeasePayablesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RightofuseassetsandleasespayableSummaryofMaturitiesofLeasePaymentsofOperatingLeaseDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#RightofuseassetsandleasespayableSummaryofMaturitiesofLeasePaymentsofOperatingLeaseDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RightofuseassetsandleasespayableSummaryofweightedaveragediscountratesfortheleasepayableDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#RightofuseassetsandleasespayableSummaryofweightedaveragediscountratesfortheleasepayableDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RightofuseassetsandleasespayableDetailsaboutleasecontractsoflowamountassetsDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#RightofuseassetsandleasespayableDetailsaboutleasecontractsoflowamountassetsDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RightofuseassetsandleasespayableAdditionalInformationDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#RightofuseassetsandleasespayableAdditionalInformationDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/PropertyPlantAndEquipmentBalancesAndChangesInPropertyPlantAndEquipmentBeginningAndEndingDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#PropertyPlantAndEquipmentBalancesAndChangesInPropertyPlantAndEquipmentBeginningAndEndingDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/IntangibleassetsBalanceandchangesinintangibleassetsDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#IntangibleassetsBalanceandchangesinintangibleassetsDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/IntangibleassetsBalancesofgoodwillDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#IntangibleassetsBalancesofgoodwillDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/IntangibleassetsBalancesofgoodwillParentheticalDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#IntangibleassetsBalancesofgoodwillParentheticalDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/IntangibleassetsAdditionalInformationDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#IntangibleassetsAdditionalInformationDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/LoansfinancingdebenturesandderivativefinancialinstrumentsSummaryofChangesinLoansDebenturesandFinanceLeasesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#LoansfinancingdebenturesandderivativefinancialinstrumentsSummaryofChangesinLoansDebenturesandFinanceLeasesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/LoansfinancingdebenturesandderivativefinancialinstrumentsSummaryofPrincipalMaturityScheduleDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#LoansfinancingdebenturesandderivativefinancialinstrumentsSummaryofPrincipalMaturityScheduleDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/LoansfinancingdebenturesandderivativefinancialinstrumentsSummaryofTransactionCostsDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#LoansfinancingdebenturesandderivativefinancialinstrumentsSummaryofTransactionCostsDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/LoansfinancingdebenturesandderivativefinancialinstrumentsSummaryofAppropriatedProfitorLossinTheFutureDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#LoansfinancingdebenturesandderivativefinancialinstrumentsSummaryofAppropriatedProfitorLossinTheFutureDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/LoansfinancingdebenturesandderivativefinancialinstrumentsSummaryofmainoperationscontractedloansDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#LoansfinancingdebenturesandderivativefinancialinstrumentsSummaryofmainoperationscontractedloansDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/LoansfinancingdebenturesandderivativefinancialinstrumentsSummaryofDebenturesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#LoansfinancingdebenturesandderivativefinancialinstrumentsSummaryofDebenturesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/LoansfinancingdebenturesandderivativefinancialinstrumentsNarrativeofDebenturesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#LoansfinancingdebenturesandderivativefinancialinstrumentsNarrativeofDebenturesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/LoansfinancingdebenturesandderivativefinancialinstrumentsSummaryofLoanMaturityDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#LoansfinancingdebenturesandderivativefinancialinstrumentsSummaryofLoanMaturityDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/LoansfinancingdebenturesandderivativefinancialinstrumentsSummaryofForeignLoanMaturityDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#LoansfinancingdebenturesandderivativefinancialinstrumentsSummaryofForeignLoanMaturityDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/LoansfinancingdebenturesandderivativefinancialinstrumentsAdditionalInformationDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#LoansfinancingdebenturesandderivativefinancialinstrumentsAdditionalInformationDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/TradePayablesSummaryOfTradePayablesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#TradePayablesSummaryOfTradePayablesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/EmployeebenefitsandprivatepensionplanAdditionalinformationDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#EmployeebenefitsandprivatepensionplanAdditionalinformationDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/EmployeebenefitsandprivatepensionplanChangesinprovisionforpostemploymentbenefitsDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#EmployeebenefitsandprivatepensionplanChangesinprovisionforpostemploymentbenefitsDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/EmployeebenefitsandprivatepensionplanPostemploymentbenefitexpenseDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#EmployeebenefitsandprivatepensionplanPostemploymentbenefitexpenseDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/EmployeebenefitsandprivatepensionplanSignificantactuarialassumptionsadoptedDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#EmployeebenefitsandprivatepensionplanSignificantactuarialassumptionsadoptedDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/EmployeebenefitsandprivatepensionplanSensitivityanalysisDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#EmployeebenefitsandprivatepensionplanSensitivityanalysisDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/ProvisionsandcontingentliabilitiesBalancesofescrowdepositsDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#ProvisionsandcontingentliabilitiesBalancesofescrowdepositsDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/ProvisionsandcontingentliabilitiesContingentliabilitiespossiblebynatureDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#ProvisionsandcontingentliabilitiesContingentliabilitiespossiblebynatureDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/ProvisionsandcontingentliabilitiesAdditionalinformationDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#ProvisionsandcontingentliabilitiesAdditionalinformationDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/DeferredRevenueDeferredRevenueInSubsidiariesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#DeferredRevenueDeferredRevenueInSubsidiariesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/DeferredRevenueAdditionalInformationDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#DeferredRevenueAdditionalInformationDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/SubscriptionWarrantsIndemnificationAdditionalInformationDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#SubscriptionWarrantsIndemnificationAdditionalInformationDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/EquityAdditionalInformationDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#EquityAdditionalInformationDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/EquityBalanceoftreasurysharesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#EquityBalanceoftreasurysharesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/EquityBalanceOfOtherComprehensiveIncomeDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#EquityBalanceOfOtherComprehensiveIncomeDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/EquityDividendsAndAllocationOfNetIncomeParentheticalDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#EquityDividendsAndAllocationOfNetIncomeParentheticalDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/EquitySummaryofBalancesandChangesinDividendsPayableDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#EquitySummaryofBalancesandChangesinDividendsPayableDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/CostsandexpensesbynatureAdditionalinformationDetails" xlink:type="simple" xlink:href="ugp-20241231.xsd#CostsandexpensesbynatureAdditionalinformationDetails" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/EarningspershareAdditionalInformationDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#EarningspershareAdditionalInformationDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/SegmentInformationRevenueFromOperationsAbroadDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#SegmentInformationRevenueFromOperationsAbroadDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/SegmentInformationRightofuseAssetsPPEandIntangibleAssetsoftheCompanyAbroadDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#SegmentInformationRightofuseAssetsPPEandIntangibleAssetsoftheCompanyAbroadDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/FinancialInstrumentsSummaryofthefinancialassetsandfinancialliabilitiesmeasuredatfairvalueDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#FinancialInstrumentsSummaryofthefinancialassetsandfinancialliabilitiesmeasuredatfairvalueDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/FinancialInstrumentsChangesinfinancialliabilitiesmeasuredatlevel3ofthefairvaluehierarchyDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#FinancialInstrumentsChangesinfinancialliabilitiesmeasuredatlevel3ofthefairvaluehierarchyDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/FinancialInstrumentsDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#FinancialInstrumentsDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/FinancialInstrumentsPositionsofderivativefinancialinstrumentstohedgecommoditypriceriskDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#FinancialInstrumentsPositionsofderivativefinancialinstrumentstohedgecommoditypriceriskDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/FinancialInstrumentsSummaryofcreditriskoffinancialinstitutionandgovernmentofcashcashequivalentsandfinancialinvestmentsDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#FinancialInstrumentsSummaryofcreditriskoffinancialinstitutionandgovernmentofcashcashequivalentsandfinancialinvestmentsDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/FinancialInstrumentsContractualundiscountedcashoutflowsDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#FinancialInstrumentsContractualundiscountedcashoutflowsDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/FinancialInstrumentsSummarythepositionofhedginginstrumentsDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#FinancialInstrumentsSummarythepositionofhedginginstrumentsDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/FinancialInstrumentsSensitivityanalysislevel2hierarchyDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#FinancialInstrumentsSensitivityanalysislevel2hierarchyDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/FinancialInstrumentsAdditionalInformationDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#FinancialInstrumentsAdditionalInformationDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RisksAndFinancialInstrumentsFinancialAssetsAndLiabilitiesExposedToFloatingInterestRatesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#RisksAndFinancialInstrumentsFinancialAssetsAndLiabilitiesExposedToFloatingInterestRatesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RisksandFinancialInstrumentsSensitivityanalysisoffloatinginterestrateriskDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#RisksandFinancialInstrumentsSensitivityanalysisoffloatinginterestrateriskDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RisksandFinancialInstrumentsLossallowanceforexpectedcreditlossesbalancesontradereceivablesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#RisksandFinancialInstrumentsLossallowanceforexpectedcreditlossesbalancesontradereceivablesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RisksandFinancialInstrumentsCreditriskexposureDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#RisksandFinancialInstrumentsCreditriskexposureDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RisksandFinancialInstrumentsSummaryoflossallowanceforexpectedcreditlossesbalancesbygeographicareaDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#RisksandFinancialInstrumentsSummaryoflossallowanceforexpectedcreditlossesbalancesbygeographicareaDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RisksandFinancialInstrumentsSummaryofforeignexchangehedginginstrumentsdesignatedasfairvaluehedgeDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#RisksandFinancialInstrumentsSummaryofforeignexchangehedginginstrumentsdesignatedasfairvaluehedgeDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/CommitmentsContractsDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#CommitmentsContractsDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/CommitmentsAdditionalInformationDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#CommitmentsAdditionalInformationDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/CommitmentsMinimumAnnualPurchasesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#CommitmentsMinimumAnnualPurchasesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/AcquisitionofInterestandControlScheduleofacquiredintangibleassetsthatwerenotrecognizedinthebooksoftheacquiredentityDetails" xlink:type="simple" xlink:href="ugp-20241231.xsd#AcquisitionofInterestandControlScheduleofacquiredintangibleassetsthatwerenotrecognizedinthebooksoftheacquiredentityDetails" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/AcquisitionofInterestandControlAdditionalInformationDetails" xlink:type="simple" xlink:href="ugp-20241231.xsd#AcquisitionofInterestandControlAdditionalInformationDetails" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/DiscontinuedoperationsDetailsTextuals" xlink:type="simple" xlink:href="ugp-20241231.xsd#DiscontinuedoperationsDetailsTextuals" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/EventsafterthereportingperiodAdditionalInformationDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#EventsafterthereportingperiodAdditionalInformationDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/InvestmentSummaryOfBalancesAndChangesInJointVenturesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#InvestmentSummaryOfBalancesAndChangesInJointVenturesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/InvestmentSummaryofprovisionforshorttermliabilitiesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#InvestmentSummaryofprovisionforshorttermliabilitiesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/InvestmentsSummaryofreconciliationofshareofprofitlossofsubsidiariesjointventuresandassociatesDetails" xlink:type="simple" xlink:href="ugp-20241231.xsd#InvestmentsSummaryofreconciliationofshareofprofitlossofsubsidiariesjointventuresandassociatesDetails" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/InvestmentSummaryOfBalancesAndChangesInAssociatesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#InvestmentSummaryOfBalancesAndChangesInAssociatesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RecoverabletaxesSummaryofestimatedrecoveryofICMSassetsDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#RecoverabletaxesSummaryofestimatedrecoveryofICMSassetsDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RecoverabletaxesSummaryofestimatedrecoveryofPISandCOFINScreditDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#RecoverabletaxesSummaryofestimatedrecoveryofPISandCOFINScreditDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RightofuseassetsandleasespayableSummaryofAmortizationExpensesintheFinancialStatementsDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#RightofuseassetsandleasespayableSummaryofAmortizationExpensesintheFinancialStatementsDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RelatedPartiesSummaryOfSubsidiariesAndOtherRelatedPartiesParentheticalDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#RelatedPartiesSummaryOfSubsidiariesAndOtherRelatedPartiesParentheticalDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/IncomeandSocialContributionTaxesSummaryoftaxlosscarryforwardsDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#IncomeandSocialContributionTaxesSummaryoftaxlosscarryforwardsDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/SegmentInformationAdditionstoPropertyPlantandEquipmentandintangibleAssetsandContractualassetswithcustomersexclusiverightsDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#SegmentInformationAdditionstoPropertyPlantandEquipmentandintangibleAssetsandContractualassetswithcustomersexclusiverightsDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/LoansfinancingdebenturesandderivativefinancialinstrumentsNotesDetailsTextual" xlink:type="simple" xlink:href="ugp-20241231.xsd#LoansfinancingdebenturesandderivativefinancialinstrumentsNotesDetailsTextual" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/DiscontinuedoperationsDetails3Textuals2" xlink:type="simple" xlink:href="ugp-20241231.xsd#DiscontinuedoperationsDetails3Textuals2" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/ProvisionforassetretirementobligationChangesintheprovisionforassetretirementobligationDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#ProvisionforassetretirementobligationChangesintheprovisionforassetretirementobligationDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/LoansfinancingdebenturesandderivativefinancialinstrumentsSummaryofCollateraltoFinancialInstitutionsDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#LoansfinancingdebenturesandderivativefinancialinstrumentsSummaryofCollateraltoFinancialInstitutionsDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RisksAndFinancialInstrumentsContractualUndiscountedCashOutflowsParentheticalDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#RisksAndFinancialInstrumentsContractualUndiscountedCashOutflowsParentheticalDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RisksAndFinancialInstrumentsValueOfGainsLossesRecognizedDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#RisksAndFinancialInstrumentsValueOfGainsLossesRecognizedDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RisksAndFinancialInstrumentsFairValuesAndTheCarryingValuesOfTheFinancialInstrumentsDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#RisksAndFinancialInstrumentsFairValuesAndTheCarryingValuesOfTheFinancialInstrumentsDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RisksAndFinancialInstrumentsChangesInExchangeRateDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#RisksAndFinancialInstrumentsChangesInExchangeRateDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RecoverabletaxesConsolidatedSummaryofRecoverableIncomeTaxandSocialContributionTaxesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#RecoverabletaxesConsolidatedSummaryofRecoverableIncomeTaxandSocialContributionTaxesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RelatedPartiesSummaryOfSharesGrantedDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#RelatedPartiesSummaryOfSharesGrantedDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/RelatedPartiesChangesOfNumberOfSharesGrantedDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#RelatedPartiesChangesOfNumberOfSharesGrantedDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/IncomeAndSocialContributionTaxesSummaryOfTaxIncentivesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#IncomeAndSocialContributionTaxesSummaryOfTaxIncentivesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/PrepaidExpensesSummaryOfPrepaidExpensesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#PrepaidExpensesSummaryOfPrepaidExpensesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/PrepaidExpensesSummaryofPrepaidExpensesDetailCalc2" xlink:type="simple" xlink:href="ugp-20241231.xsd#PrepaidExpensesSummaryofPrepaidExpensesDetailCalc2" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/EquityBalanceAndChangesInCumulativeTranslationAdjustmentsDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#EquityBalanceAndChangesInCumulativeTranslationAdjustmentsDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/AcquisitionofInterestandControlScheduleofearnoutsensitivityanalysisDetails" xlink:type="simple" xlink:href="ugp-20241231.xsd#AcquisitionofInterestandControlScheduleofearnoutsensitivityanalysisDetails" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/AcquisitionofInterestandControlScheduleofbreakdownoftheacquisitionvalueconsideringtheworkingcapitalandnetdebtadjustmentsandprimarycontributionDetails" xlink:type="simple" xlink:href="ugp-20241231.xsd#AcquisitionofInterestandControlScheduleofbreakdownoftheacquisitionvalueconsideringtheworkingcapitalandnetdebtadjustmentsandprimarycontributionDetails" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/SalariesAndRelatedChargesSummaryOfSalariesAndRelatedChargesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#SalariesAndRelatedChargesSummaryOfSalariesAndRelatedChargesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/TaxesPayableSummaryOfTaxesPayableDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#TaxesPayableSummaryOfTaxesPayableDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/GainlossondisposalofpropertyplantandequipmentandintangibleassetsAdditionalinformationDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#GainlossondisposalofpropertyplantandequipmentandintangibleassetsAdditionalinformationDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/OtheroperatingincomenetOtheroperatingincomenetDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#OtheroperatingincomenetOtheroperatingincomenetDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/InvestmentsinsubsidiariesjointventuresandassociatesSummaryofAmountsofBalanceSheetsandIncomeStatementsofAssociatesDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#InvestmentsinsubsidiariesjointventuresandassociatesSummaryofAmountsofBalanceSheetsandIncomeStatementsofAssociatesDetail" />
  <link:roleRef roleURI="http://www.ultrapar.com/role/PropertyPlantAndEquipmentSummaryOfDepreciationExpensesInTheFinancialStatementsDetail" xlink:type="simple" xlink:href="ugp-20241231.xsd#PropertyPlantAndEquipmentSummaryOfDepreciationExpensesInTheFinancialStatementsDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Consolidatedstatementsofcomprehensiveincome">
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ComprehensiveIncome" xlink:label="ifrs-full_ComprehensiveIncome" xlink:title="ifrs-full_ComprehensiveIncome" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ProfitLoss" xlink:label="ifrs-full_ProfitLoss" xlink:title="ifrs-full_ProfitLoss" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ComprehensiveIncome" xlink:to="ifrs-full_ProfitLoss" xlink:title="Calculation : ifrs-full_ComprehensiveIncome to ifrs-full_ProfitLoss" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ProfitLossAttributableToOwnersOfParent" xlink:label="ifrs-full_ProfitLossAttributableToOwnersOfParent" xlink:title="ifrs-full_ProfitLossAttributableToOwnersOfParent" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ProfitLoss" xlink:to="ifrs-full_ProfitLossAttributableToOwnersOfParent" xlink:title="Calculation : ifrs-full_ProfitLoss to ifrs-full_ProfitLossAttributableToOwnersOfParent" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ProfitLossAttributableToNoncontrollingInterests" xlink:label="ifrs-full_ProfitLossAttributableToNoncontrollingInterests" xlink:title="ifrs-full_ProfitLossAttributableToNoncontrollingInterests" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ProfitLoss" xlink:to="ifrs-full_ProfitLossAttributableToNoncontrollingInterests" xlink:title="Calculation : ifrs-full_ProfitLoss to ifrs-full_ProfitLossAttributableToNoncontrollingInterests" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_OtherComprehensiveIncomeNetOfTaxFinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncome" xlink:label="ifrs-full_OtherComprehensiveIncomeNetOfTaxFinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncome" xlink:title="ifrs-full_OtherComprehensiveIncomeNetOfTaxFinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncome" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ComprehensiveIncome" xlink:to="ifrs-full_OtherComprehensiveIncomeNetOfTaxFinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncome" xlink:title="Calculation : ifrs-full_ComprehensiveIncome to ifrs-full_OtherComprehensiveIncomeNetOfTaxFinancialAssetsMeasuredAtFairValueThroughOtherComprehensiveIncome" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_OtherComprehensiveIncomeNetOfTaxExchangeDifferencesOnTranslationOfForeignOperationsAndHedgesOfNetInvestmentsInForeignOperations" xlink:label="ifrs-full_OtherComprehensiveIncomeNetOfTaxExchangeDifferencesOnTranslationOfForeignOperationsAndHedgesOfNetInvestmentsInForeignOperations" xlink:title="ifrs-full_OtherComprehensiveIncomeNetOfTaxExchangeDifferencesOnTranslationOfForeignOperationsAndHedgesOfNetInvestmentsInForeignOperations" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ComprehensiveIncome" xlink:to="ifrs-full_OtherComprehensiveIncomeNetOfTaxExchangeDifferencesOnTranslationOfForeignOperationsAndHedgesOfNetInvestmentsInForeignOperations" xlink:title="Calculation : ifrs-full_ComprehensiveIncome to ifrs-full_OtherComprehensiveIncomeNetOfTaxExchangeDifferencesOnTranslationOfForeignOperationsAndHedgesOfNetInvestmentsInForeignOperations" order="2" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_OtherComprehensiveIncomeNetOfTaxGainsLossesOnRemeasurementsOfDefinedBenefitPlans" xlink:label="ifrs-full_OtherComprehensiveIncomeNetOfTaxGainsLossesOnRemeasurementsOfDefinedBenefitPlans" xlink:title="ifrs-full_OtherComprehensiveIncomeNetOfTaxGainsLossesOnRemeasurementsOfDefinedBenefitPlans" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ComprehensiveIncome" xlink:to="ifrs-full_OtherComprehensiveIncomeNetOfTaxGainsLossesOnRemeasurementsOfDefinedBenefitPlans" xlink:title="Calculation : ifrs-full_ComprehensiveIncome to ifrs-full_OtherComprehensiveIncomeNetOfTaxGainsLossesOnRemeasurementsOfDefinedBenefitPlans" order="3" weight="1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/EquityDividendsAndAllocationOfNetIncomeDetail">
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_AdjustedNetIncomeBasisForDividends" xlink:label="ugp_AdjustedNetIncomeBasisForDividends" xlink:title="ugp_AdjustedNetIncomeBasisForDividends" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ProfitLossAttributableToOwnersOfParent" xlink:label="ifrs-full_ProfitLossAttributableToOwnersOfParent" xlink:title="ifrs-full_ProfitLossAttributableToOwnersOfParent" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_AdjustedNetIncomeBasisForDividends" xlink:to="ifrs-full_ProfitLossAttributableToOwnersOfParent" xlink:title="Calculation : ugp_AdjustedNetIncomeBasisForDividends to ifrs-full_ProfitLossAttributableToOwnersOfParent" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_AllocationToLegalReserves" xlink:label="ugp_AllocationToLegalReserves" xlink:title="ugp_AllocationToLegalReserves" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_AdjustedNetIncomeBasisForDividends" xlink:to="ugp_AllocationToLegalReserves" xlink:title="Calculation : ugp_AdjustedNetIncomeBasisForDividends to ugp_AllocationToLegalReserves" order="1" weight="-1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_DividendsProposedOrDeclaredBeforeFinancialStatementsAuthorisedForIssueButNotRecognisedAsDistributionToOwners" xlink:label="ifrs-full_DividendsProposedOrDeclaredBeforeFinancialStatementsAuthorisedForIssueButNotRecognisedAsDistributionToOwners" xlink:title="ifrs-full_DividendsProposedOrDeclaredBeforeFinancialStatementsAuthorisedForIssueButNotRecognisedAsDistributionToOwners" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_MinimumMandatoryDividends" xlink:label="ugp_MinimumMandatoryDividends" xlink:title="ugp_MinimumMandatoryDividends" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_DividendsProposedOrDeclaredBeforeFinancialStatementsAuthorisedForIssueButNotRecognisedAsDistributionToOwners" xlink:to="ugp_MinimumMandatoryDividends" xlink:title="Calculation : ifrs-full_DividendsProposedOrDeclaredBeforeFinancialStatementsAuthorisedForIssueButNotRecognisedAsDistributionToOwners to ugp_MinimumMandatoryDividends" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_InterimDividendsPaid" xlink:label="ugp_InterimDividendsPaid" xlink:title="ugp_InterimDividendsPaid" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_DividendsProposedOrDeclaredBeforeFinancialStatementsAuthorisedForIssueButNotRecognisedAsDistributionToOwners" xlink:to="ugp_InterimDividendsPaid" xlink:title="Calculation : ifrs-full_DividendsProposedOrDeclaredBeforeFinancialStatementsAuthorisedForIssueButNotRecognisedAsDistributionToOwners to ugp_InterimDividendsPaid" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_InterestOnCapitalPaidNetOfIncomeTax" xlink:label="ugp_InterestOnCapitalPaidNetOfIncomeTax" xlink:title="ugp_InterestOnCapitalPaidNetOfIncomeTax" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_DividendsProposedOrDeclaredBeforeFinancialStatementsAuthorisedForIssueButNotRecognisedAsDistributionToOwners" xlink:to="ugp_InterestOnCapitalPaidNetOfIncomeTax" xlink:title="Calculation : ifrs-full_DividendsProposedOrDeclaredBeforeFinancialStatementsAuthorisedForIssueButNotRecognisedAsDistributionToOwners to ugp_InterestOnCapitalPaidNetOfIncomeTax" order="2" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_AdditionalDividendsToMinimumMandatoryDividendsRecognised" xlink:label="ugp_AdditionalDividendsToMinimumMandatoryDividendsRecognised" xlink:title="ugp_AdditionalDividendsToMinimumMandatoryDividendsRecognised" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_DividendsProposedOrDeclaredBeforeFinancialStatementsAuthorisedForIssueButNotRecognisedAsDistributionToOwners" xlink:to="ugp_AdditionalDividendsToMinimumMandatoryDividendsRecognised" xlink:title="Calculation : ifrs-full_DividendsProposedOrDeclaredBeforeFinancialStatementsAuthorisedForIssueButNotRecognisedAsDistributionToOwners to ugp_AdditionalDividendsToMinimumMandatoryDividendsRecognised" order="3" weight="1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/IncomeAndSocialContributionTaxesDeferredTaxesDetail">
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_DeferredTaxAssets" xlink:label="ifrs-full_DeferredTaxAssets" xlink:title="ifrs-full_DeferredTaxAssets" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_DeferredIncomeAndSocialContributionTaxAssets" xlink:label="ugp_DeferredIncomeAndSocialContributionTaxAssets" xlink:title="ugp_DeferredIncomeAndSocialContributionTaxAssets" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_DeferredTaxAssets" xlink:to="ugp_DeferredIncomeAndSocialContributionTaxAssets" xlink:title="Calculation : ifrs-full_DeferredTaxAssets to ugp_DeferredIncomeAndSocialContributionTaxAssets" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_DeferredIncomeAndSocialContributionTaxesProvisionForImpairmentOfAssets" xlink:label="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForImpairmentOfAssets" xlink:title="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForImpairmentOfAssets" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_DeferredIncomeAndSocialContributionTaxAssets" xlink:to="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForImpairmentOfAssets" xlink:title="Calculation : ugp_DeferredIncomeAndSocialContributionTaxAssets to ugp_DeferredIncomeAndSocialContributionTaxesProvisionForImpairmentOfAssets" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_DeferredIncomeAndSocialContributionTaxesProvisionsFortaxCivilAndLaborRisks" xlink:label="ugp_DeferredIncomeAndSocialContributionTaxesProvisionsFortaxCivilAndLaborRisks" xlink:title="ugp_DeferredIncomeAndSocialContributionTaxesProvisionsFortaxCivilAndLaborRisks" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_DeferredIncomeAndSocialContributionTaxAssets" xlink:to="ugp_DeferredIncomeAndSocialContributionTaxesProvisionsFortaxCivilAndLaborRisks" xlink:title="Calculation : ugp_DeferredIncomeAndSocialContributionTaxAssets to ugp_DeferredIncomeAndSocialContributionTaxesProvisionsFortaxCivilAndLaborRisks" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_DeferredIncomeAndSocialContributionTaxesProvisionForPostEmploymentBenefits" xlink:label="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForPostEmploymentBenefits" xlink:title="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForPostEmploymentBenefits" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_DeferredIncomeAndSocialContributionTaxAssets" xlink:to="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForPostEmploymentBenefits" xlink:title="Calculation : ugp_DeferredIncomeAndSocialContributionTaxAssets to ugp_DeferredIncomeAndSocialContributionTaxesProvisionForPostEmploymentBenefits" order="2" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_DeferredIncomeAndSocialContributionTaxesProvisionForDifferencesBetweenCashAndAccrualBasisAssets" xlink:label="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForDifferencesBetweenCashAndAccrualBasisAssets" xlink:title="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForDifferencesBetweenCashAndAccrualBasisAssets" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_DeferredIncomeAndSocialContributionTaxAssets" xlink:to="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForDifferencesBetweenCashAndAccrualBasisAssets" xlink:title="Calculation : ugp_DeferredIncomeAndSocialContributionTaxAssets to ugp_DeferredIncomeAndSocialContributionTaxesProvisionForDifferencesBetweenCashAndAccrualBasisAssets" order="3" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_DeferredincomeAndSocialContributionTaxesGoodwill" xlink:label="ugp_DeferredincomeAndSocialContributionTaxesGoodwill" xlink:title="ugp_DeferredincomeAndSocialContributionTaxesGoodwill" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_DeferredIncomeAndSocialContributionTaxAssets" xlink:to="ugp_DeferredincomeAndSocialContributionTaxesGoodwill" xlink:title="Calculation : ugp_DeferredIncomeAndSocialContributionTaxAssets to ugp_DeferredincomeAndSocialContributionTaxesGoodwill" order="4" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_DeferredIncomeAndSocialContributionTaxesBusinessCombinationFiscalBasisAccountingBasisOfGoodwill" xlink:label="ugp_DeferredIncomeAndSocialContributionTaxesBusinessCombinationFiscalBasisAccountingBasisOfGoodwill" xlink:title="ugp_DeferredIncomeAndSocialContributionTaxesBusinessCombinationFiscalBasisAccountingBasisOfGoodwill" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_DeferredIncomeAndSocialContributionTaxAssets" xlink:to="ugp_DeferredIncomeAndSocialContributionTaxesBusinessCombinationFiscalBasisAccountingBasisOfGoodwill" xlink:title="Calculation : ugp_DeferredIncomeAndSocialContributionTaxAssets to ugp_DeferredIncomeAndSocialContributionTaxesBusinessCombinationFiscalBasisAccountingBasisOfGoodwill" order="5" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_DeferredIncomeAndSocialContributionTaxesProvisionForAssetRetirementObligation" xlink:label="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForAssetRetirementObligation" xlink:title="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForAssetRetirementObligation" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_DeferredIncomeAndSocialContributionTaxAssets" xlink:to="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForAssetRetirementObligation" xlink:title="Calculation : ugp_DeferredIncomeAndSocialContributionTaxAssets to ugp_DeferredIncomeAndSocialContributionTaxesProvisionForAssetRetirementObligation" order="6" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_DeferredIncomeAndSocialContributionTaxesProvisionForSuppliers" xlink:label="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForSuppliers" xlink:title="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForSuppliers" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_DeferredIncomeAndSocialContributionTaxAssets" xlink:to="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForSuppliers" xlink:title="Calculation : ugp_DeferredIncomeAndSocialContributionTaxAssets to ugp_DeferredIncomeAndSocialContributionTaxesProvisionForSuppliers" order="7" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_DeferredIncomeAndSocialContributionTaxesProvisionForProfitSharingAndBonus" xlink:label="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForProfitSharingAndBonus" xlink:title="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForProfitSharingAndBonus" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_DeferredIncomeAndSocialContributionTaxAssets" xlink:to="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForProfitSharingAndBonus" xlink:title="Calculation : ugp_DeferredIncomeAndSocialContributionTaxAssets to ugp_DeferredIncomeAndSocialContributionTaxesProvisionForProfitSharingAndBonus" order="8" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_DeferredIncomeAndSocialContributionTaxesLeasesPayable" xlink:label="ugp_DeferredIncomeAndSocialContributionTaxesLeasesPayable" xlink:title="ugp_DeferredIncomeAndSocialContributionTaxesLeasesPayable" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_DeferredIncomeAndSocialContributionTaxAssets" xlink:to="ugp_DeferredIncomeAndSocialContributionTaxesLeasesPayable" xlink:title="Calculation : ugp_DeferredIncomeAndSocialContributionTaxAssets to ugp_DeferredIncomeAndSocialContributionTaxesLeasesPayable" order="9" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_DeferredIncomeAndSocialContributionTaxesChangeInFairValueOfSubscriptionWarrants" xlink:label="ugp_DeferredIncomeAndSocialContributionTaxesChangeInFairValueOfSubscriptionWarrants" xlink:title="ugp_DeferredIncomeAndSocialContributionTaxesChangeInFairValueOfSubscriptionWarrants" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_DeferredIncomeAndSocialContributionTaxAssets" xlink:to="ugp_DeferredIncomeAndSocialContributionTaxesChangeInFairValueOfSubscriptionWarrants" xlink:title="Calculation : ugp_DeferredIncomeAndSocialContributionTaxAssets to ugp_DeferredIncomeAndSocialContributionTaxesChangeInFairValueOfSubscriptionWarrants" order="10" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_DeferredIncomeAndSocialContributionTaxesProvisionForDeferredRevenue" xlink:label="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForDeferredRevenue" xlink:title="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForDeferredRevenue" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_DeferredIncomeAndSocialContributionTaxAssets" xlink:to="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForDeferredRevenue" xlink:title="Calculation : ugp_DeferredIncomeAndSocialContributionTaxAssets to ugp_DeferredIncomeAndSocialContributionTaxesProvisionForDeferredRevenue" order="11" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_DeferredIncomeAndSocialContributionTaxesOtherProvisions" xlink:label="ugp_DeferredIncomeAndSocialContributionTaxesOtherProvisions" xlink:title="ugp_DeferredIncomeAndSocialContributionTaxesOtherProvisions" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_DeferredIncomeAndSocialContributionTaxAssets" xlink:to="ugp_DeferredIncomeAndSocialContributionTaxesOtherProvisions" xlink:title="Calculation : ugp_DeferredIncomeAndSocialContributionTaxAssets to ugp_DeferredIncomeAndSocialContributionTaxesOtherProvisions" order="12" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_DeferredIncomeAndSocialContributionTaxesTaxLossesAndNegativeBasisForSocialContributionCarryforwards" xlink:label="ugp_DeferredIncomeAndSocialContributionTaxesTaxLossesAndNegativeBasisForSocialContributionCarryforwards" xlink:title="ugp_DeferredIncomeAndSocialContributionTaxesTaxLossesAndNegativeBasisForSocialContributionCarryforwards" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_DeferredIncomeAndSocialContributionTaxAssets" xlink:to="ugp_DeferredIncomeAndSocialContributionTaxesTaxLossesAndNegativeBasisForSocialContributionCarryforwards" xlink:title="Calculation : ugp_DeferredIncomeAndSocialContributionTaxAssets to ugp_DeferredIncomeAndSocialContributionTaxesTaxLossesAndNegativeBasisForSocialContributionCarryforwards" order="13" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_DeferredIncomeAndSocialContributioTaxesOffsetLiabilitiesBalance" xlink:label="ugp_DeferredIncomeAndSocialContributioTaxesOffsetLiabilitiesBalance" xlink:title="ugp_DeferredIncomeAndSocialContributioTaxesOffsetLiabilitiesBalance" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_DeferredTaxAssets" xlink:to="ugp_DeferredIncomeAndSocialContributioTaxesOffsetLiabilitiesBalance" xlink:title="Calculation : ifrs-full_DeferredTaxAssets to ugp_DeferredIncomeAndSocialContributioTaxesOffsetLiabilitiesBalance" order="1" weight="-1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_DeferredTaxLiabilities" xlink:label="ifrs-full_DeferredTaxLiabilities" xlink:title="ifrs-full_DeferredTaxLiabilities" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_DeferredIncomeAndSocialContributionTaxLiabilities" xlink:label="ugp_DeferredIncomeAndSocialContributionTaxLiabilities" xlink:title="ugp_DeferredIncomeAndSocialContributionTaxLiabilities" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_DeferredTaxLiabilities" xlink:to="ugp_DeferredIncomeAndSocialContributionTaxLiabilities" xlink:title="Calculation : ifrs-full_DeferredTaxLiabilities to ugp_DeferredIncomeAndSocialContributionTaxLiabilities" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_DeferredIncomeAndSocialContributionTaxesRevaluationOfPropertyPlantAndEquipment" xlink:label="ugp_DeferredIncomeAndSocialContributionTaxesRevaluationOfPropertyPlantAndEquipment" xlink:title="ugp_DeferredIncomeAndSocialContributionTaxesRevaluationOfPropertyPlantAndEquipment" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_DeferredIncomeAndSocialContributionTaxLiabilities" xlink:to="ugp_DeferredIncomeAndSocialContributionTaxesRevaluationOfPropertyPlantAndEquipment" xlink:title="Calculation : ugp_DeferredIncomeAndSocialContributionTaxLiabilities to ugp_DeferredIncomeAndSocialContributionTaxesRevaluationOfPropertyPlantAndEquipment" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_DeferredIncomeAndSocialContributionTaxesLease" xlink:label="ugp_DeferredIncomeAndSocialContributionTaxesLease" xlink:title="ugp_DeferredIncomeAndSocialContributionTaxesLease" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_DeferredIncomeAndSocialContributionTaxLiabilities" xlink:to="ugp_DeferredIncomeAndSocialContributionTaxesLease" xlink:title="Calculation : ugp_DeferredIncomeAndSocialContributionTaxLiabilities to ugp_DeferredIncomeAndSocialContributionTaxesLease" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_DeferredIncomeAndSocialContributionTaxesProvisionForChangeInFairValueOfSubscriptionWarrants" xlink:label="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForChangeInFairValueOfSubscriptionWarrants" xlink:title="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForChangeInFairValueOfSubscriptionWarrants" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_DeferredIncomeAndSocialContributionTaxLiabilities" xlink:to="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForChangeInFairValueOfSubscriptionWarrants" xlink:title="Calculation : ugp_DeferredIncomeAndSocialContributionTaxLiabilities to ugp_DeferredIncomeAndSocialContributionTaxesProvisionForChangeInFairValueOfSubscriptionWarrants" order="2" weight="1" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_DeferredIncomeAndSocialContributionTaxesProvisionForDifferencesBetweenCashAndAccrualBasisLiabilities" xlink:label="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForDifferencesBetweenCashAndAccrualBasisLiabilities" xlink:title="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForDifferencesBetweenCashAndAccrualBasisLiabilities" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_DeferredIncomeAndSocialContributionTaxLiabilities" xlink:to="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForDifferencesBetweenCashAndAccrualBasisLiabilities" xlink:title="Calculation : ugp_DeferredIncomeAndSocialContributionTaxLiabilities to ugp_DeferredIncomeAndSocialContributionTaxesProvisionForDifferencesBetweenCashAndAccrualBasisLiabilities" order="3" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_DeferredIncomeAndSocialContributionTaxesProvisionForPostemploymentBenefitsProvisionForGoodwillAndNegativeGoodwill" xlink:label="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForPostemploymentBenefitsProvisionForGoodwillAndNegativeGoodwill" xlink:title="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForPostemploymentBenefitsProvisionForGoodwillAndNegativeGoodwill" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_DeferredIncomeAndSocialContributionTaxLiabilities" xlink:to="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForPostemploymentBenefitsProvisionForGoodwillAndNegativeGoodwill" xlink:title="Calculation : ugp_DeferredIncomeAndSocialContributionTaxLiabilities to ugp_DeferredIncomeAndSocialContributionTaxesProvisionForPostemploymentBenefitsProvisionForGoodwillAndNegativeGoodwill" order="4" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_DeferredIncomeAndSocialContributionTaxesProvisionForPostemploymentBenefitsBusinessCombinationFairValueOfAssets" xlink:label="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForPostemploymentBenefitsBusinessCombinationFairValueOfAssets" xlink:title="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForPostemploymentBenefitsBusinessCombinationFairValueOfAssets" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_DeferredIncomeAndSocialContributionTaxLiabilities" xlink:to="ugp_DeferredIncomeAndSocialContributionTaxesProvisionForPostemploymentBenefitsBusinessCombinationFairValueOfAssets" xlink:title="Calculation : ugp_DeferredIncomeAndSocialContributionTaxLiabilities to ugp_DeferredIncomeAndSocialContributionTaxesProvisionForPostemploymentBenefitsBusinessCombinationFairValueOfAssets" order="5" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_DeferredIncomeAndSocialContributionTaxesOtherProvisionsLiabilities" xlink:label="ugp_DeferredIncomeAndSocialContributionTaxesOtherProvisionsLiabilities" xlink:title="ugp_DeferredIncomeAndSocialContributionTaxesOtherProvisionsLiabilities" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_DeferredIncomeAndSocialContributionTaxLiabilities" xlink:to="ugp_DeferredIncomeAndSocialContributionTaxesOtherProvisionsLiabilities" xlink:title="Calculation : ugp_DeferredIncomeAndSocialContributionTaxLiabilities to ugp_DeferredIncomeAndSocialContributionTaxesOtherProvisionsLiabilities" order="6" weight="-1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_DeferredIncomeAndSocialContributionTaxesOffsetAssetsBalance" xlink:label="ugp_DeferredIncomeAndSocialContributionTaxesOffsetAssetsBalance" xlink:title="ugp_DeferredIncomeAndSocialContributionTaxesOffsetAssetsBalance" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_DeferredTaxLiabilities" xlink:to="ugp_DeferredIncomeAndSocialContributionTaxesOffsetAssetsBalance" xlink:title="Calculation : ifrs-full_DeferredTaxLiabilities to ugp_DeferredIncomeAndSocialContributionTaxesOffsetAssetsBalance" order="1" weight="-1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/SegmentInformationAssetsBySegmentsDetail">
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_Assets" xlink:label="ifrs-full_Assets" xlink:title="ifrs-full_Assets" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_InvestmentAccountedForUsingEquityMethod" xlink:label="ifrs-full_InvestmentAccountedForUsingEquityMethod" xlink:title="ifrs-full_InvestmentAccountedForUsingEquityMethod" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_Assets" xlink:to="ifrs-full_InvestmentAccountedForUsingEquityMethod" xlink:title="Calculation : ifrs-full_Assets to ifrs-full_InvestmentAccountedForUsingEquityMethod" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_PropertyPlantAndEquipment" xlink:label="ifrs-full_PropertyPlantAndEquipment" xlink:title="ifrs-full_PropertyPlantAndEquipment" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_Assets" xlink:to="ifrs-full_PropertyPlantAndEquipment" xlink:title="Calculation : ifrs-full_Assets to ifrs-full_PropertyPlantAndEquipment" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_IntangibleAssetsAndGoodwill" xlink:label="ifrs-full_IntangibleAssetsAndGoodwill" xlink:title="ifrs-full_IntangibleAssetsAndGoodwill" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_Assets" xlink:to="ifrs-full_IntangibleAssetsAndGoodwill" xlink:title="Calculation : ifrs-full_Assets to ifrs-full_IntangibleAssetsAndGoodwill" order="2" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_RightofuseAssets" xlink:label="ifrs-full_RightofuseAssets" xlink:title="ifrs-full_RightofuseAssets" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_Assets" xlink:to="ifrs-full_RightofuseAssets" xlink:title="Calculation : ifrs-full_Assets to ifrs-full_RightofuseAssets" order="3" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_OtherCurrentAndNoncurrentAssets" xlink:label="ugp_OtherCurrentAndNoncurrentAssets" xlink:title="ugp_OtherCurrentAndNoncurrentAssets" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_Assets" xlink:to="ugp_OtherCurrentAndNoncurrentAssets" xlink:title="Calculation : ifrs-full_Assets to ugp_OtherCurrentAndNoncurrentAssets" order="4" weight="1" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/FinancialInstrumentsScheduleofleverageratioDetail">
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_NetDebt" xlink:label="ifrs-full_NetDebt" xlink:title="ifrs-full_NetDebt" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_LoansFinancingAndLeasesPayable" xlink:label="ugp_LoansFinancingAndLeasesPayable" xlink:title="ugp_LoansFinancingAndLeasesPayable" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_NetDebt" xlink:to="ugp_LoansFinancingAndLeasesPayable" xlink:title="Calculation : ifrs-full_NetDebt to ugp_LoansFinancingAndLeasesPayable" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_CashAndCashEquivalentsFinancialInvestmentsAndDerivativeHedgeFinancialInstruments" xlink:label="ugp_CashAndCashEquivalentsFinancialInvestmentsAndDerivativeHedgeFinancialInstruments" xlink:title="ugp_CashAndCashEquivalentsFinancialInvestmentsAndDerivativeHedgeFinancialInstruments" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_NetDebt" xlink:to="ugp_CashAndCashEquivalentsFinancialInvestmentsAndDerivativeHedgeFinancialInstruments" xlink:title="Calculation : ifrs-full_NetDebt to ugp_CashAndCashEquivalentsFinancialInvestmentsAndDerivativeHedgeFinancialInstruments" order="1" weight="-1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/FinancialInstrumentsAssetsandliabilitiesinforeigncurrenciesDetailCalc2">
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_NetAssetLiabilityPositionTotal" xlink:label="ugp_NetAssetLiabilityPositionTotal" xlink:title="ugp_NetAssetLiabilityPositionTotal" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_NetAssetLiabilityPositionEffectStatementIncome" xlink:label="ugp_NetAssetLiabilityPositionEffectStatementIncome" xlink:title="ugp_NetAssetLiabilityPositionEffectStatementIncome" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_NetAssetLiabilityPositionTotal" xlink:to="ugp_NetAssetLiabilityPositionEffectStatementIncome" xlink:title="Calculation : ugp_NetAssetLiabilityPositionTotal to ugp_NetAssetLiabilityPositionEffectStatementIncome" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_NetAssetLiabilityPositionShareholdersEffectEquity" xlink:label="ugp_NetAssetLiabilityPositionShareholdersEffectEquity" xlink:title="ugp_NetAssetLiabilityPositionShareholdersEffectEquity" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_NetAssetLiabilityPositionTotal" xlink:to="ugp_NetAssetLiabilityPositionShareholdersEffectEquity" xlink:title="Calculation : ugp_NetAssetLiabilityPositionTotal to ugp_NetAssetLiabilityPositionShareholdersEffectEquity" order="1" weight="1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/ProvisionsandcontingentliabilitiesBreakdownofprovisionsbynatureDetail">
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_OtherProvisions" xlink:label="ifrs-full_OtherProvisions" xlink:title="ifrs-full_OtherProvisions" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ShorttermLegalProceedingsProvision" xlink:label="ifrs-full_ShorttermLegalProceedingsProvision" xlink:title="ifrs-full_ShorttermLegalProceedingsProvision" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_OtherProvisions" xlink:to="ifrs-full_ShorttermLegalProceedingsProvision" xlink:title="Calculation : ifrs-full_OtherProvisions to ifrs-full_ShorttermLegalProceedingsProvision" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_LongtermLegalProceedingsProvision" xlink:label="ifrs-full_LongtermLegalProceedingsProvision" xlink:title="ifrs-full_LongtermLegalProceedingsProvision" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_OtherProvisions" xlink:to="ifrs-full_LongtermLegalProceedingsProvision" xlink:title="Calculation : ifrs-full_OtherProvisions to ifrs-full_LongtermLegalProceedingsProvision" order="1" weight="1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/EmployeebenefitsandprivatepensionplanPostemploymentBenefitsDetail">
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ProvisionsForEmployeeBenefits" xlink:label="ifrs-full_ProvisionsForEmployeeBenefits" xlink:title="ifrs-full_ProvisionsForEmployeeBenefits" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CurrentProvisionsForEmployeeBenefits" xlink:label="ifrs-full_CurrentProvisionsForEmployeeBenefits" xlink:title="ifrs-full_CurrentProvisionsForEmployeeBenefits" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ProvisionsForEmployeeBenefits" xlink:to="ifrs-full_CurrentProvisionsForEmployeeBenefits" xlink:title="Calculation : ifrs-full_ProvisionsForEmployeeBenefits to ifrs-full_CurrentProvisionsForEmployeeBenefits" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_NoncurrentProvisionsForEmployeeBenefits" xlink:label="ifrs-full_NoncurrentProvisionsForEmployeeBenefits" xlink:title="ifrs-full_NoncurrentProvisionsForEmployeeBenefits" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ProvisionsForEmployeeBenefits" xlink:to="ifrs-full_NoncurrentProvisionsForEmployeeBenefits" xlink:title="Calculation : ifrs-full_ProvisionsForEmployeeBenefits to ifrs-full_NoncurrentProvisionsForEmployeeBenefits" order="1" weight="1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RelatedPartiesRestrictedStockProgramDetail">
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_GrantCostsIncludingTaxes" xlink:label="ugp_GrantCostsIncludingTaxes" xlink:title="ugp_GrantCostsIncludingTaxes" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_AccumulatedRecognizedGrantCostsRelatedParties" xlink:label="ugp_AccumulatedRecognizedGrantCostsRelatedParties" xlink:title="ugp_AccumulatedRecognizedGrantCostsRelatedParties" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_GrantCostsIncludingTaxes" xlink:to="ugp_AccumulatedRecognizedGrantCostsRelatedParties" xlink:title="Calculation : ugp_GrantCostsIncludingTaxes to ugp_AccumulatedRecognizedGrantCostsRelatedParties" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_AccumulatedUnrecognizedGrantCostsRelatedParties" xlink:label="ugp_AccumulatedUnrecognizedGrantCostsRelatedParties" xlink:title="ugp_AccumulatedUnrecognizedGrantCostsRelatedParties" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_GrantCostsIncludingTaxes" xlink:to="ugp_AccumulatedUnrecognizedGrantCostsRelatedParties" xlink:title="Calculation : ugp_GrantCostsIncludingTaxes to ugp_AccumulatedUnrecognizedGrantCostsRelatedParties" order="1" weight="1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RecoverabletaxesSummaryofRecoverableTaxesDetail">
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ReceivablesFromTaxesOtherThanIncomeTax" xlink:label="ifrs-full_ReceivablesFromTaxesOtherThanIncomeTax" xlink:title="ifrs-full_ReceivablesFromTaxesOtherThanIncomeTax" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CurrentReceivablesFromTaxesOtherThanIncomeTax" xlink:label="ifrs-full_CurrentReceivablesFromTaxesOtherThanIncomeTax" xlink:title="ifrs-full_CurrentReceivablesFromTaxesOtherThanIncomeTax" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ReceivablesFromTaxesOtherThanIncomeTax" xlink:to="ifrs-full_CurrentReceivablesFromTaxesOtherThanIncomeTax" xlink:title="Calculation : ifrs-full_ReceivablesFromTaxesOtherThanIncomeTax to ifrs-full_CurrentReceivablesFromTaxesOtherThanIncomeTax" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_NoncurrentReceivablesFromTaxesOtherThanIncomeTax" xlink:label="ifrs-full_NoncurrentReceivablesFromTaxesOtherThanIncomeTax" xlink:title="ifrs-full_NoncurrentReceivablesFromTaxesOtherThanIncomeTax" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ReceivablesFromTaxesOtherThanIncomeTax" xlink:to="ifrs-full_NoncurrentReceivablesFromTaxesOtherThanIncomeTax" xlink:title="Calculation : ifrs-full_ReceivablesFromTaxesOtherThanIncomeTax to ifrs-full_NoncurrentReceivablesFromTaxesOtherThanIncomeTax" order="1" weight="1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/TradeReceivablesandResellerFinancingCompositionofResellerFinancingDetailCalc2">
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_ResellerFinancing" xlink:label="ugp_ResellerFinancing" xlink:title="ugp_ResellerFinancing" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_ResellerFinancingGross" xlink:label="ugp_ResellerFinancingGross" xlink:title="ugp_ResellerFinancingGross" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_ResellerFinancing" xlink:to="ugp_ResellerFinancingGross" xlink:title="Calculation : ugp_ResellerFinancing to ugp_ResellerFinancingGross" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_AllowanceAccountForCreditLossesOfFinancialAssets" xlink:label="ifrs-full_AllowanceAccountForCreditLossesOfFinancialAssets" xlink:title="ifrs-full_AllowanceAccountForCreditLossesOfFinancialAssets" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_ResellerFinancing" xlink:to="ifrs-full_AllowanceAccountForCreditLossesOfFinancialAssets" xlink:title="Calculation : ugp_ResellerFinancing to ifrs-full_AllowanceAccountForCreditLossesOfFinancialAssets" order="1" weight="-1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/TradereceivablesresellerfinancingandotherreceivablesCompositionofResellerFinancingDetail">
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_ResellerFinancing" xlink:label="ugp_ResellerFinancing" xlink:title="ugp_ResellerFinancing" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_CurrentResellerFinancing" xlink:label="ugp_CurrentResellerFinancing" xlink:title="ugp_CurrentResellerFinancing" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_ResellerFinancing" xlink:to="ugp_CurrentResellerFinancing" xlink:title="Calculation : ugp_ResellerFinancing to ugp_CurrentResellerFinancing" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_NonCurrentResellerFinancing" xlink:label="ugp_NonCurrentResellerFinancing" xlink:title="ugp_NonCurrentResellerFinancing" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_ResellerFinancing" xlink:to="ugp_NonCurrentResellerFinancing" xlink:title="Calculation : ugp_ResellerFinancing to ugp_NonCurrentResellerFinancing" order="1" weight="1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/TradereceivablesresellerfinancingandotherreceivablesTradereceivablesDetail">
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_TradeReceivables" xlink:label="ifrs-full_TradeReceivables" xlink:title="ifrs-full_TradeReceivables" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CurrentTradeReceivables" xlink:label="ifrs-full_CurrentTradeReceivables" xlink:title="ifrs-full_CurrentTradeReceivables" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_TradeReceivables" xlink:to="ifrs-full_CurrentTradeReceivables" xlink:title="Calculation : ifrs-full_TradeReceivables to ifrs-full_CurrentTradeReceivables" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_NoncurrentTradeReceivables" xlink:label="ifrs-full_NoncurrentTradeReceivables" xlink:title="ifrs-full_NoncurrentTradeReceivables" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_TradeReceivables" xlink:to="ifrs-full_NoncurrentTradeReceivables" xlink:title="Calculation : ifrs-full_TradeReceivables to ifrs-full_NoncurrentTradeReceivables" order="1" weight="1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/CashandCashEquivalentsandFinancialInvestmentsFinancialinvestmentsDetailCalc2">
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_FinancialInvestments" xlink:label="ugp_FinancialInvestments" xlink:title="ugp_FinancialInvestments" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_FinancialInvestmentsCurrent" xlink:label="ugp_FinancialInvestmentsCurrent" xlink:title="ugp_FinancialInvestmentsCurrent" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_FinancialInvestments" xlink:to="ugp_FinancialInvestmentsCurrent" xlink:title="Calculation : ugp_FinancialInvestments to ugp_FinancialInvestmentsCurrent" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_FinancialInvestmentsNoncurrent" xlink:label="ugp_FinancialInvestmentsNoncurrent" xlink:title="ugp_FinancialInvestmentsNoncurrent" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_FinancialInvestments" xlink:to="ugp_FinancialInvestmentsNoncurrent" xlink:title="Calculation : ugp_FinancialInvestments to ugp_FinancialInvestmentsNoncurrent" order="1" weight="1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Consolidatedstatementsofchangesinequity">
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ComprehensiveIncome" xlink:label="ifrs-full_ComprehensiveIncome" xlink:title="ifrs-full_ComprehensiveIncome" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ProfitLoss" xlink:label="ifrs-full_ProfitLoss" xlink:title="ifrs-full_ProfitLoss" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ComprehensiveIncome" xlink:to="ifrs-full_ProfitLoss" xlink:title="Calculation : ifrs-full_ComprehensiveIncome to ifrs-full_ProfitLoss" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_OtherComprehensiveIncome" xlink:label="ifrs-full_OtherComprehensiveIncome" xlink:title="ifrs-full_OtherComprehensiveIncome" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ComprehensiveIncome" xlink:to="ifrs-full_OtherComprehensiveIncome" xlink:title="Calculation : ifrs-full_ComprehensiveIncome to ifrs-full_OtherComprehensiveIncome" order="1" weight="1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/ConsolidatedstatementsofcomprehensiveincomeCalc2">
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ComprehensiveIncome" xlink:label="ifrs-full_ComprehensiveIncome" xlink:title="ifrs-full_ComprehensiveIncome" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ComprehensiveIncomeAttributableToOwnersOfParent" xlink:label="ifrs-full_ComprehensiveIncomeAttributableToOwnersOfParent" xlink:title="ifrs-full_ComprehensiveIncomeAttributableToOwnersOfParent" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ComprehensiveIncome" xlink:to="ifrs-full_ComprehensiveIncomeAttributableToOwnersOfParent" xlink:title="Calculation : ifrs-full_ComprehensiveIncome to ifrs-full_ComprehensiveIncomeAttributableToOwnersOfParent" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ComprehensiveIncomeAttributableToNoncontrollingInterests" xlink:label="ifrs-full_ComprehensiveIncomeAttributableToNoncontrollingInterests" xlink:title="ifrs-full_ComprehensiveIncomeAttributableToNoncontrollingInterests" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ComprehensiveIncome" xlink:to="ifrs-full_ComprehensiveIncomeAttributableToNoncontrollingInterests" xlink:title="Calculation : ifrs-full_ComprehensiveIncome to ifrs-full_ComprehensiveIncomeAttributableToNoncontrollingInterests" order="1" weight="1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/ConsolidatedstatementsofincomeCalc2">
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ProfitLoss" xlink:label="ifrs-full_ProfitLoss" xlink:title="ifrs-full_ProfitLoss" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ProfitLossAttributableToOwnersOfParent" xlink:label="ifrs-full_ProfitLossAttributableToOwnersOfParent" xlink:title="ifrs-full_ProfitLossAttributableToOwnersOfParent" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ProfitLoss" xlink:to="ifrs-full_ProfitLossAttributableToOwnersOfParent" xlink:title="Calculation : ifrs-full_ProfitLoss to ifrs-full_ProfitLossAttributableToOwnersOfParent" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ProfitLossAttributableToNoncontrollingInterests" xlink:label="ifrs-full_ProfitLossAttributableToNoncontrollingInterests" xlink:title="ifrs-full_ProfitLossAttributableToNoncontrollingInterests" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ProfitLoss" xlink:to="ifrs-full_ProfitLossAttributableToNoncontrollingInterests" xlink:title="Calculation : ifrs-full_ProfitLoss to ifrs-full_ProfitLossAttributableToNoncontrollingInterests" order="1" weight="1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Consolidatedstatementsofincome">
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ProfitLoss" xlink:label="ifrs-full_ProfitLoss" xlink:title="ifrs-full_ProfitLoss" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ProfitLossFromContinuingOperations" xlink:label="ifrs-full_ProfitLossFromContinuingOperations" xlink:title="ifrs-full_ProfitLossFromContinuingOperations" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ProfitLoss" xlink:to="ifrs-full_ProfitLossFromContinuingOperations" xlink:title="Calculation : ifrs-full_ProfitLoss to ifrs-full_ProfitLossFromContinuingOperations" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ProfitLossBeforeTax" xlink:label="ifrs-full_ProfitLossBeforeTax" xlink:title="ifrs-full_ProfitLossBeforeTax" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ProfitLossFromContinuingOperations" xlink:to="ifrs-full_ProfitLossBeforeTax" xlink:title="Calculation : ifrs-full_ProfitLossFromContinuingOperations to ifrs-full_ProfitLossBeforeTax" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndIncomeAndSocialContributionTaxes" xlink:label="ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndIncomeAndSocialContributionTaxes" xlink:title="ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndIncomeAndSocialContributionTaxes" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ProfitLossBeforeTax" xlink:to="ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndIncomeAndSocialContributionTaxes" xlink:title="Calculation : ifrs-full_ProfitLossBeforeTax to ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndIncomeAndSocialContributionTaxes" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndShareOfProfitLossOfJointVenturesAndAssociates" xlink:label="ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndShareOfProfitLossOfJointVenturesAndAssociates" xlink:title="ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndShareOfProfitLossOfJointVenturesAndAssociates" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndIncomeAndSocialContributionTaxes" xlink:to="ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndShareOfProfitLossOfJointVenturesAndAssociates" xlink:title="Calculation : ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndIncomeAndSocialContributionTaxes to ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndShareOfProfitLossOfJointVenturesAndAssociates" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_GrossProfit" xlink:label="ifrs-full_GrossProfit" xlink:title="ifrs-full_GrossProfit" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndShareOfProfitLossOfJointVenturesAndAssociates" xlink:to="ifrs-full_GrossProfit" xlink:title="Calculation : ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndShareOfProfitLossOfJointVenturesAndAssociates to ifrs-full_GrossProfit" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_Revenue" xlink:label="ifrs-full_Revenue" xlink:title="ifrs-full_Revenue" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_GrossProfit" xlink:to="ifrs-full_Revenue" xlink:title="Calculation : ifrs-full_GrossProfit to ifrs-full_Revenue" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CostOfSales" xlink:label="ifrs-full_CostOfSales" xlink:title="ifrs-full_CostOfSales" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_GrossProfit" xlink:to="ifrs-full_CostOfSales" xlink:title="Calculation : ifrs-full_GrossProfit to ifrs-full_CostOfSales" order="1" weight="-1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_GainsLossesOnDisposalsOfNoncurrentAssets" xlink:label="ifrs-full_GainsLossesOnDisposalsOfNoncurrentAssets" xlink:title="ifrs-full_GainsLossesOnDisposalsOfNoncurrentAssets" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndShareOfProfitLossOfJointVenturesAndAssociates" xlink:to="ifrs-full_GainsLossesOnDisposalsOfNoncurrentAssets" xlink:title="Calculation : ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndShareOfProfitLossOfJointVenturesAndAssociates to ifrs-full_GainsLossesOnDisposalsOfNoncurrentAssets" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_GeneralAndAdministrativeExpense" xlink:label="ifrs-full_GeneralAndAdministrativeExpense" xlink:title="ifrs-full_GeneralAndAdministrativeExpense" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndShareOfProfitLossOfJointVenturesAndAssociates" xlink:to="ifrs-full_GeneralAndAdministrativeExpense" xlink:title="Calculation : ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndShareOfProfitLossOfJointVenturesAndAssociates to ifrs-full_GeneralAndAdministrativeExpense" order="2" weight="-1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_SalesAndMarketingExpense" xlink:label="ifrs-full_SalesAndMarketingExpense" xlink:title="ifrs-full_SalesAndMarketingExpense" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndShareOfProfitLossOfJointVenturesAndAssociates" xlink:to="ifrs-full_SalesAndMarketingExpense" xlink:title="Calculation : ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndShareOfProfitLossOfJointVenturesAndAssociates to ifrs-full_SalesAndMarketingExpense" order="3" weight="-1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_OtherOperatingIncomeExpense" xlink:label="ifrs-full_OtherOperatingIncomeExpense" xlink:title="ifrs-full_OtherOperatingIncomeExpense" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndShareOfProfitLossOfJointVenturesAndAssociates" xlink:to="ifrs-full_OtherOperatingIncomeExpense" xlink:title="Calculation : ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndShareOfProfitLossOfJointVenturesAndAssociates to ifrs-full_OtherOperatingIncomeExpense" order="4" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ImpairmentLossRecognisedInProfitOrLoss" xlink:label="ifrs-full_ImpairmentLossRecognisedInProfitOrLoss" xlink:title="ifrs-full_ImpairmentLossRecognisedInProfitOrLoss" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndShareOfProfitLossOfJointVenturesAndAssociates" xlink:to="ifrs-full_ImpairmentLossRecognisedInProfitOrLoss" xlink:title="Calculation : ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndShareOfProfitLossOfJointVenturesAndAssociates to ifrs-full_ImpairmentLossRecognisedInProfitOrLoss" order="5" weight="-1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ShareOfProfitLossOfAssociatesAndJointVenturesAccountedForUsingEquityMethod" xlink:label="ifrs-full_ShareOfProfitLossOfAssociatesAndJointVenturesAccountedForUsingEquityMethod" xlink:title="ifrs-full_ShareOfProfitLossOfAssociatesAndJointVenturesAccountedForUsingEquityMethod" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndIncomeAndSocialContributionTaxes" xlink:to="ifrs-full_ShareOfProfitLossOfAssociatesAndJointVenturesAccountedForUsingEquityMethod" xlink:title="Calculation : ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndIncomeAndSocialContributionTaxes to ifrs-full_ShareOfProfitLossOfAssociatesAndJointVenturesAccountedForUsingEquityMethod" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_ShareOfProfitLossOfAssociatesAndJointVenturesAccountedForUsingEquityMethodBeforeAdjustments" xlink:label="ugp_ShareOfProfitLossOfAssociatesAndJointVenturesAccountedForUsingEquityMethodBeforeAdjustments" xlink:title="ugp_ShareOfProfitLossOfAssociatesAndJointVenturesAccountedForUsingEquityMethodBeforeAdjustments" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ShareOfProfitLossOfAssociatesAndJointVenturesAccountedForUsingEquityMethod" xlink:to="ugp_ShareOfProfitLossOfAssociatesAndJointVenturesAccountedForUsingEquityMethodBeforeAdjustments" xlink:title="Calculation : ifrs-full_ShareOfProfitLossOfAssociatesAndJointVenturesAccountedForUsingEquityMethod to ugp_ShareOfProfitLossOfAssociatesAndJointVenturesAccountedForUsingEquityMethodBeforeAdjustments" order="0" weight="1" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_AmortizationOfFairValueAdjustmentOnInvestmentAccountedForUsingEquityMethod" xlink:label="ugp_AmortizationOfFairValueAdjustmentOnInvestmentAccountedForUsingEquityMethod" xlink:title="ugp_AmortizationOfFairValueAdjustmentOnInvestmentAccountedForUsingEquityMethod" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ShareOfProfitLossOfAssociatesAndJointVenturesAccountedForUsingEquityMethod" xlink:to="ugp_AmortizationOfFairValueAdjustmentOnInvestmentAccountedForUsingEquityMethod" xlink:title="Calculation : ifrs-full_ShareOfProfitLossOfAssociatesAndJointVenturesAccountedForUsingEquityMethod to ugp_AmortizationOfFairValueAdjustmentOnInvestmentAccountedForUsingEquityMethod" order="1" weight="-1" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ShareOfProfitLossOfAssociatesAccountedForUsingEquityMethod" xlink:label="ifrs-full_ShareOfProfitLossOfAssociatesAccountedForUsingEquityMethod" xlink:title="ifrs-full_ShareOfProfitLossOfAssociatesAccountedForUsingEquityMethod" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndIncomeAndSocialContributionTaxes" xlink:to="ifrs-full_ShareOfProfitLossOfAssociatesAccountedForUsingEquityMethod" xlink:title="Calculation : ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndIncomeAndSocialContributionTaxes to ifrs-full_ShareOfProfitLossOfAssociatesAccountedForUsingEquityMethod" order="2" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_FinanceIncomeCost" xlink:label="ifrs-full_FinanceIncomeCost" xlink:title="ifrs-full_FinanceIncomeCost" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ProfitLossBeforeTax" xlink:to="ifrs-full_FinanceIncomeCost" xlink:title="Calculation : ifrs-full_ProfitLossBeforeTax to ifrs-full_FinanceIncomeCost" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_FinanceIncome" xlink:label="ifrs-full_FinanceIncome" xlink:title="ifrs-full_FinanceIncome" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_FinanceIncomeCost" xlink:to="ifrs-full_FinanceIncome" xlink:title="Calculation : ifrs-full_FinanceIncomeCost to ifrs-full_FinanceIncome" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_FinanceCosts" xlink:label="ifrs-full_FinanceCosts" xlink:title="ifrs-full_FinanceCosts" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_FinanceIncomeCost" xlink:to="ifrs-full_FinanceCosts" xlink:title="Calculation : ifrs-full_FinanceIncomeCost to ifrs-full_FinanceCosts" order="1" weight="-1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_IncomeTaxExpenseContinuingOperations" xlink:label="ifrs-full_IncomeTaxExpenseContinuingOperations" xlink:title="ifrs-full_IncomeTaxExpenseContinuingOperations" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ProfitLossFromContinuingOperations" xlink:to="ifrs-full_IncomeTaxExpenseContinuingOperations" xlink:title="Calculation : ifrs-full_ProfitLossFromContinuingOperations to ifrs-full_IncomeTaxExpenseContinuingOperations" order="1" weight="-1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CurrentTaxExpenseIncome" xlink:label="ifrs-full_CurrentTaxExpenseIncome" xlink:title="ifrs-full_CurrentTaxExpenseIncome" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_IncomeTaxExpenseContinuingOperations" xlink:to="ifrs-full_CurrentTaxExpenseIncome" xlink:title="Calculation : ifrs-full_IncomeTaxExpenseContinuingOperations to ifrs-full_CurrentTaxExpenseIncome" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_DeferredTaxExpenseIncome" xlink:label="ifrs-full_DeferredTaxExpenseIncome" xlink:title="ifrs-full_DeferredTaxExpenseIncome" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_IncomeTaxExpenseContinuingOperations" xlink:to="ifrs-full_DeferredTaxExpenseIncome" xlink:title="Calculation : ifrs-full_IncomeTaxExpenseContinuingOperations to ifrs-full_DeferredTaxExpenseIncome" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ProfitLossFromDiscontinuedOperations" xlink:label="ifrs-full_ProfitLossFromDiscontinuedOperations" xlink:title="ifrs-full_ProfitLossFromDiscontinuedOperations" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ProfitLoss" xlink:to="ifrs-full_ProfitLossFromDiscontinuedOperations" xlink:title="Calculation : ifrs-full_ProfitLoss to ifrs-full_ProfitLossFromDiscontinuedOperations" order="1" weight="1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/FinancialInstrumentsAssetsandliabilitiesexposedtoforeigncurrencytranslatedtoReaisandorexposedtofloatinginterestratesDetail">
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_NetAssetLiabilityPositionTotal" xlink:label="ugp_NetAssetLiabilityPositionTotal" xlink:title="ugp_NetAssetLiabilityPositionTotal" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_AssetsInForeignCurrency" xlink:label="ugp_AssetsInForeignCurrency" xlink:title="ugp_AssetsInForeignCurrency" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_NetAssetLiabilityPositionTotal" xlink:to="ugp_AssetsInForeignCurrency" xlink:title="Calculation : ugp_NetAssetLiabilityPositionTotal to ugp_AssetsInForeignCurrency" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_CashCashEquivalentsAndFinancialInvestmentsInForeignCurrencyExceptHedgingInstruments" xlink:label="ugp_CashCashEquivalentsAndFinancialInvestmentsInForeignCurrencyExceptHedgingInstruments" xlink:title="ugp_CashCashEquivalentsAndFinancialInvestmentsInForeignCurrencyExceptHedgingInstruments" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_AssetsInForeignCurrency" xlink:to="ugp_CashCashEquivalentsAndFinancialInvestmentsInForeignCurrencyExceptHedgingInstruments" xlink:title="Calculation : ugp_AssetsInForeignCurrency to ugp_CashCashEquivalentsAndFinancialInvestmentsInForeignCurrencyExceptHedgingInstruments" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_ForeignTradeReceivablesNetOfAllowanceForDoubtfulAccountsAndAdvancesToForeignCustomers" xlink:label="ugp_ForeignTradeReceivablesNetOfAllowanceForDoubtfulAccountsAndAdvancesToForeignCustomers" xlink:title="ugp_ForeignTradeReceivablesNetOfAllowanceForDoubtfulAccountsAndAdvancesToForeignCustomers" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_AssetsInForeignCurrency" xlink:to="ugp_ForeignTradeReceivablesNetOfAllowanceForDoubtfulAccountsAndAdvancesToForeignCustomers" xlink:title="Calculation : ugp_AssetsInForeignCurrency to ugp_ForeignTradeReceivablesNetOfAllowanceForDoubtfulAccountsAndAdvancesToForeignCustomers" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_OtherReceivablesInForeignCurrency" xlink:label="ugp_OtherReceivablesInForeignCurrency" xlink:title="ugp_OtherReceivablesInForeignCurrency" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_AssetsInForeignCurrency" xlink:to="ugp_OtherReceivablesInForeignCurrency" xlink:title="Calculation : ugp_AssetsInForeignCurrency to ugp_OtherReceivablesInForeignCurrency" order="2" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_OtherNetAssetsOfForeignSubsidiariesInForeignCurrencyExceptCashCashEquivalentsFinancialInvestmentsTradeReceivablesFinancingAndPayables" xlink:label="ugp_OtherNetAssetsOfForeignSubsidiariesInForeignCurrencyExceptCashCashEquivalentsFinancialInvestmentsTradeReceivablesFinancingAndPayables" xlink:title="ugp_OtherNetAssetsOfForeignSubsidiariesInForeignCurrencyExceptCashCashEquivalentsFinancialInvestmentsTradeReceivablesFinancingAndPayables" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_AssetsInForeignCurrency" xlink:to="ugp_OtherNetAssetsOfForeignSubsidiariesInForeignCurrencyExceptCashCashEquivalentsFinancialInvestmentsTradeReceivablesFinancingAndPayables" xlink:title="Calculation : ugp_AssetsInForeignCurrency to ugp_OtherNetAssetsOfForeignSubsidiariesInForeignCurrencyExceptCashCashEquivalentsFinancialInvestmentsTradeReceivablesFinancingAndPayables" order="3" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_InventoriesTotal" xlink:label="ifrs-full_InventoriesTotal" xlink:title="ifrs-full_InventoriesTotal" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_AssetsInForeignCurrency" xlink:to="ifrs-full_InventoriesTotal" xlink:title="Calculation : ugp_AssetsInForeignCurrency to ifrs-full_InventoriesTotal" order="4" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_LiabilitiesInForeignCurrency" xlink:label="ugp_LiabilitiesInForeignCurrency" xlink:title="ugp_LiabilitiesInForeignCurrency" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_NetAssetLiabilityPositionTotal" xlink:to="ugp_LiabilitiesInForeignCurrency" xlink:title="Calculation : ugp_NetAssetLiabilityPositionTotal to ugp_LiabilitiesInForeignCurrency" order="1" weight="-1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_FinancingInForeignCurrency" xlink:label="ugp_FinancingInForeignCurrency" xlink:title="ugp_FinancingInForeignCurrency" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_LiabilitiesInForeignCurrency" xlink:to="ugp_FinancingInForeignCurrency" xlink:title="Calculation : ugp_LiabilitiesInForeignCurrency to ugp_FinancingInForeignCurrency" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_PayablesArisingFromImports" xlink:label="ugp_PayablesArisingFromImports" xlink:title="ugp_PayablesArisingFromImports" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_LiabilitiesInForeignCurrency" xlink:to="ugp_PayablesArisingFromImports" xlink:title="Calculation : ugp_LiabilitiesInForeignCurrency to ugp_PayablesArisingFromImports" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_LiabilitiesExposureFromSubsidiariesHeldForSale" xlink:label="ugp_LiabilitiesExposureFromSubsidiariesHeldForSale" xlink:title="ugp_LiabilitiesExposureFromSubsidiariesHeldForSale" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_LiabilitiesInForeignCurrency" xlink:to="ugp_LiabilitiesExposureFromSubsidiariesHeldForSale" xlink:title="Calculation : ugp_LiabilitiesInForeignCurrency to ugp_LiabilitiesExposureFromSubsidiariesHeldForSale" order="2" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_NetAssetsLiabilitiesPositionExposedToFloatingInterestRates" xlink:label="ugp_NetAssetsLiabilitiesPositionExposedToFloatingInterestRates" xlink:title="ugp_NetAssetsLiabilitiesPositionExposedToFloatingInterestRates" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_LiabilitiesInForeignCurrency" xlink:to="ugp_NetAssetsLiabilitiesPositionExposedToFloatingInterestRates" xlink:title="Calculation : ugp_LiabilitiesInForeignCurrency to ugp_NetAssetsLiabilitiesPositionExposedToFloatingInterestRates" order="3" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_ForeignCurrencyHedgingInstruments" xlink:label="ugp_ForeignCurrencyHedgingInstruments" xlink:title="ugp_ForeignCurrencyHedgingInstruments" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_NetAssetLiabilityPositionTotal" xlink:to="ugp_ForeignCurrencyHedgingInstruments" xlink:title="Calculation : ugp_NetAssetLiabilityPositionTotal to ugp_ForeignCurrencyHedgingInstruments" order="2" weight="1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Consolidatedstatementsofcashflowsindirectmethod">
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CashFlowsFromUsedInOperatingActivities" xlink:label="ifrs-full_CashFlowsFromUsedInOperatingActivities" xlink:title="ifrs-full_CashFlowsFromUsedInOperatingActivities" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations" xlink:label="ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations" xlink:title="ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInOperatingActivities" xlink:to="ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInOperatingActivities to ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CashFlowsFromUsedInOperationsBeforeChangesInWorkingCapital" xlink:label="ifrs-full_CashFlowsFromUsedInOperationsBeforeChangesInWorkingCapital" xlink:title="ifrs-full_CashFlowsFromUsedInOperationsBeforeChangesInWorkingCapital" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations" xlink:to="ifrs-full_CashFlowsFromUsedInOperationsBeforeChangesInWorkingCapital" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations to ifrs-full_CashFlowsFromUsedInOperationsBeforeChangesInWorkingCapital" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ProfitLossFromContinuingOperations" xlink:label="ifrs-full_ProfitLossFromContinuingOperations" xlink:title="ifrs-full_ProfitLossFromContinuingOperations" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInOperationsBeforeChangesInWorkingCapital" xlink:to="ifrs-full_ProfitLossFromContinuingOperations" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInOperationsBeforeChangesInWorkingCapital to ifrs-full_ProfitLossFromContinuingOperations" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_AdjustmentsForUndistributedProfitsAndAmortizationOfFairValueAdjustmentsOfInvestmentsAccountedForUsingEquityMethod" xlink:label="ugp_AdjustmentsForUndistributedProfitsAndAmortizationOfFairValueAdjustmentsOfInvestmentsAccountedForUsingEquityMethod" xlink:title="ugp_AdjustmentsForUndistributedProfitsAndAmortizationOfFairValueAdjustmentsOfInvestmentsAccountedForUsingEquityMethod" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInOperationsBeforeChangesInWorkingCapital" xlink:to="ugp_AdjustmentsForUndistributedProfitsAndAmortizationOfFairValueAdjustmentsOfInvestmentsAccountedForUsingEquityMethod" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInOperationsBeforeChangesInWorkingCapital to ugp_AdjustmentsForUndistributedProfitsAndAmortizationOfFairValueAdjustmentsOfInvestmentsAccountedForUsingEquityMethod" order="1" weight="-1" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_AmortisationAssetsRecognisedFromCostsIncurredToObtainOrFulfilContractsWithCustomers" xlink:label="ifrs-full_AmortisationAssetsRecognisedFromCostsIncurredToObtainOrFulfilContractsWithCustomers" xlink:title="ifrs-full_AmortisationAssetsRecognisedFromCostsIncurredToObtainOrFulfilContractsWithCustomers" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInOperationsBeforeChangesInWorkingCapital" xlink:to="ifrs-full_AmortisationAssetsRecognisedFromCostsIncurredToObtainOrFulfilContractsWithCustomers" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInOperationsBeforeChangesInWorkingCapital to ifrs-full_AmortisationAssetsRecognisedFromCostsIncurredToObtainOrFulfilContractsWithCustomers" order="2" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_AdjustmentsForAmortizationOfRightOfUseAssets" xlink:label="ugp_AdjustmentsForAmortizationOfRightOfUseAssets" xlink:title="ugp_AdjustmentsForAmortizationOfRightOfUseAssets" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInOperationsBeforeChangesInWorkingCapital" xlink:to="ugp_AdjustmentsForAmortizationOfRightOfUseAssets" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInOperationsBeforeChangesInWorkingCapital to ugp_AdjustmentsForAmortizationOfRightOfUseAssets" order="3" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_AdjustmentsForDepreciationAndAmortisationExpense" xlink:label="ifrs-full_AdjustmentsForDepreciationAndAmortisationExpense" xlink:title="ifrs-full_AdjustmentsForDepreciationAndAmortisationExpense" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInOperationsBeforeChangesInWorkingCapital" xlink:to="ifrs-full_AdjustmentsForDepreciationAndAmortisationExpense" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInOperationsBeforeChangesInWorkingCapital to ifrs-full_AdjustmentsForDepreciationAndAmortisationExpense" order="4" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_AdjustmentsForInterestAndForeignExchangeRateVariations" xlink:label="ugp_AdjustmentsForInterestAndForeignExchangeRateVariations" xlink:title="ugp_AdjustmentsForInterestAndForeignExchangeRateVariations" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInOperationsBeforeChangesInWorkingCapital" xlink:to="ugp_AdjustmentsForInterestAndForeignExchangeRateVariations" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInOperationsBeforeChangesInWorkingCapital to ugp_AdjustmentsForInterestAndForeignExchangeRateVariations" order="5" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_AdjustmentsForCurrentTaxExpenseAndDeferredTaxExpense" xlink:label="ugp_AdjustmentsForCurrentTaxExpenseAndDeferredTaxExpense" xlink:title="ugp_AdjustmentsForCurrentTaxExpenseAndDeferredTaxExpense" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInOperationsBeforeChangesInWorkingCapital" xlink:to="ugp_AdjustmentsForCurrentTaxExpenseAndDeferredTaxExpense" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInOperationsBeforeChangesInWorkingCapital to ugp_AdjustmentsForCurrentTaxExpenseAndDeferredTaxExpense" order="6" weight="1" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_AdjustmentsForLossesGainsOnDisposalOfNoncurrentAssets" xlink:label="ifrs-full_AdjustmentsForLossesGainsOnDisposalOfNoncurrentAssets" xlink:title="ifrs-full_AdjustmentsForLossesGainsOnDisposalOfNoncurrentAssets" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInOperationsBeforeChangesInWorkingCapital" xlink:to="ifrs-full_AdjustmentsForLossesGainsOnDisposalOfNoncurrentAssets" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInOperationsBeforeChangesInWorkingCapital to ifrs-full_AdjustmentsForLossesGainsOnDisposalOfNoncurrentAssets" order="7" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_AdjustmentsForSharebasedPayments" xlink:label="ifrs-full_AdjustmentsForSharebasedPayments" xlink:title="ifrs-full_AdjustmentsForSharebasedPayments" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInOperationsBeforeChangesInWorkingCapital" xlink:to="ifrs-full_AdjustmentsForSharebasedPayments" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInOperationsBeforeChangesInWorkingCapital to ifrs-full_AdjustmentsForSharebasedPayments" order="8" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_AdjustmentsForGainLossOnFairValueOfEnergyContracts" xlink:label="ugp_AdjustmentsForGainLossOnFairValueOfEnergyContracts" xlink:title="ugp_AdjustmentsForGainLossOnFairValueOfEnergyContracts" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInOperationsBeforeChangesInWorkingCapital" xlink:to="ugp_AdjustmentsForGainLossOnFairValueOfEnergyContracts" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInOperationsBeforeChangesInWorkingCapital to ugp_AdjustmentsForGainLossOnFairValueOfEnergyContracts" order="9" weight="-1" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_AdjustmentsForProvisionOfDecarbonization" xlink:label="ugp_AdjustmentsForProvisionOfDecarbonization" xlink:title="ugp_AdjustmentsForProvisionOfDecarbonization" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInOperationsBeforeChangesInWorkingCapital" xlink:to="ugp_AdjustmentsForProvisionOfDecarbonization" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInOperationsBeforeChangesInWorkingCapital to ugp_AdjustmentsForProvisionOfDecarbonization" order="10" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_AdjustmentsForOtherProvisionsAndAdjustments" xlink:label="ugp_AdjustmentsForOtherProvisionsAndAdjustments" xlink:title="ugp_AdjustmentsForOtherProvisionsAndAdjustments" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInOperationsBeforeChangesInWorkingCapital" xlink:to="ugp_AdjustmentsForOtherProvisionsAndAdjustments" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInOperationsBeforeChangesInWorkingCapital to ugp_AdjustmentsForOtherProvisionsAndAdjustments" order="11" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_AdjustmentsForDecreaseIncreaseInTradeAccountReceivable" xlink:label="ifrs-full_AdjustmentsForDecreaseIncreaseInTradeAccountReceivable" xlink:title="ifrs-full_AdjustmentsForDecreaseIncreaseInTradeAccountReceivable" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations" xlink:to="ifrs-full_AdjustmentsForDecreaseIncreaseInTradeAccountReceivable" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations to ifrs-full_AdjustmentsForDecreaseIncreaseInTradeAccountReceivable" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_AdjustmentsForDecreaseIncreaseInInventories" xlink:label="ifrs-full_AdjustmentsForDecreaseIncreaseInInventories" xlink:title="ifrs-full_AdjustmentsForDecreaseIncreaseInInventories" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations" xlink:to="ifrs-full_AdjustmentsForDecreaseIncreaseInInventories" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations to ifrs-full_AdjustmentsForDecreaseIncreaseInInventories" order="2" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_AdjustmentsForDecreaseIncreaseInRecoverableTaxes" xlink:label="ugp_AdjustmentsForDecreaseIncreaseInRecoverableTaxes" xlink:title="ugp_AdjustmentsForDecreaseIncreaseInRecoverableTaxes" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations" xlink:to="ugp_AdjustmentsForDecreaseIncreaseInRecoverableTaxes" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations to ugp_AdjustmentsForDecreaseIncreaseInRecoverableTaxes" order="3" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_DividendsReceivedClassifiedAsOperatingActivities" xlink:label="ifrs-full_DividendsReceivedClassifiedAsOperatingActivities" xlink:title="ifrs-full_DividendsReceivedClassifiedAsOperatingActivities" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations" xlink:to="ifrs-full_DividendsReceivedClassifiedAsOperatingActivities" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations to ifrs-full_DividendsReceivedClassifiedAsOperatingActivities" order="4" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_AdjustmentsForDecreaseIncreaseInOtherAssets" xlink:label="ifrs-full_AdjustmentsForDecreaseIncreaseInOtherAssets" xlink:title="ifrs-full_AdjustmentsForDecreaseIncreaseInOtherAssets" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations" xlink:to="ifrs-full_AdjustmentsForDecreaseIncreaseInOtherAssets" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations to ifrs-full_AdjustmentsForDecreaseIncreaseInOtherAssets" order="5" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_AdjustmentsForIncreaseDecreaseInTradeAccountPayable" xlink:label="ifrs-full_AdjustmentsForIncreaseDecreaseInTradeAccountPayable" xlink:title="ifrs-full_AdjustmentsForIncreaseDecreaseInTradeAccountPayable" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations" xlink:to="ifrs-full_AdjustmentsForIncreaseDecreaseInTradeAccountPayable" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations to ifrs-full_AdjustmentsForIncreaseDecreaseInTradeAccountPayable" order="6" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_AdjustmentsForIncreaseDecreaseInSalariesAndRelatedCharges" xlink:label="ugp_AdjustmentsForIncreaseDecreaseInSalariesAndRelatedCharges" xlink:title="ugp_AdjustmentsForIncreaseDecreaseInSalariesAndRelatedCharges" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations" xlink:to="ugp_AdjustmentsForIncreaseDecreaseInSalariesAndRelatedCharges" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations to ugp_AdjustmentsForIncreaseDecreaseInSalariesAndRelatedCharges" order="7" weight="-1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_AdjustmentsForIncreaseDecreaseInTaxesPayable" xlink:label="ugp_AdjustmentsForIncreaseDecreaseInTaxesPayable" xlink:title="ugp_AdjustmentsForIncreaseDecreaseInTaxesPayable" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations" xlink:to="ugp_AdjustmentsForIncreaseDecreaseInTaxesPayable" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations to ugp_AdjustmentsForIncreaseDecreaseInTaxesPayable" order="8" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_AdjustmentsForIncreaseDecreaseInOtherLiabilities" xlink:label="ifrs-full_AdjustmentsForIncreaseDecreaseInOtherLiabilities" xlink:title="ifrs-full_AdjustmentsForIncreaseDecreaseInOtherLiabilities" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations" xlink:to="ifrs-full_AdjustmentsForIncreaseDecreaseInOtherLiabilities" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations to ifrs-full_AdjustmentsForIncreaseDecreaseInOtherLiabilities" order="9" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_AdjustmentsForIncreaseDecreaseInAcquisitionOfDecarbonizationCredits" xlink:label="ugp_AdjustmentsForIncreaseDecreaseInAcquisitionOfDecarbonizationCredits" xlink:title="ugp_AdjustmentsForIncreaseDecreaseInAcquisitionOfDecarbonizationCredits" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations" xlink:to="ugp_AdjustmentsForIncreaseDecreaseInAcquisitionOfDecarbonizationCredits" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations to ugp_AdjustmentsForIncreaseDecreaseInAcquisitionOfDecarbonizationCredits" order="10" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_AdjustmentsForIncreaseDecreaseInNonCurrentPaymentsOfContractualAssetsWithCustomersExclusiveRights" xlink:label="ugp_AdjustmentsForIncreaseDecreaseInNonCurrentPaymentsOfContractualAssetsWithCustomersExclusiveRights" xlink:title="ugp_AdjustmentsForIncreaseDecreaseInNonCurrentPaymentsOfContractualAssetsWithCustomersExclusiveRights" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations" xlink:to="ugp_AdjustmentsForIncreaseDecreaseInNonCurrentPaymentsOfContractualAssetsWithCustomersExclusiveRights" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations to ugp_AdjustmentsForIncreaseDecreaseInNonCurrentPaymentsOfContractualAssetsWithCustomersExclusiveRights" order="11" weight="-1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_AdjustmentsForIncreaseDecreaseInPaymentsOfContingencies" xlink:label="ugp_AdjustmentsForIncreaseDecreaseInPaymentsOfContingencies" xlink:title="ugp_AdjustmentsForIncreaseDecreaseInPaymentsOfContingencies" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations" xlink:to="ugp_AdjustmentsForIncreaseDecreaseInPaymentsOfContingencies" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations to ugp_AdjustmentsForIncreaseDecreaseInPaymentsOfContingencies" order="12" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_AdjustmentsForIncreaseDecreaseInLiabilitiesFromIncomeAndSocialContributionTaxesPaid" xlink:label="ugp_AdjustmentsForIncreaseDecreaseInLiabilitiesFromIncomeAndSocialContributionTaxesPaid" xlink:title="ugp_AdjustmentsForIncreaseDecreaseInLiabilitiesFromIncomeAndSocialContributionTaxesPaid" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations" xlink:to="ugp_AdjustmentsForIncreaseDecreaseInLiabilitiesFromIncomeAndSocialContributionTaxesPaid" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations to ugp_AdjustmentsForIncreaseDecreaseInLiabilitiesFromIncomeAndSocialContributionTaxesPaid" order="13" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CashFlowsFromUsedInOperatingActivitiesDiscontinuedOperations" xlink:label="ifrs-full_CashFlowsFromUsedInOperatingActivitiesDiscontinuedOperations" xlink:title="ifrs-full_CashFlowsFromUsedInOperatingActivitiesDiscontinuedOperations" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInOperatingActivities" xlink:to="ifrs-full_CashFlowsFromUsedInOperatingActivitiesDiscontinuedOperations" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInOperatingActivities to ifrs-full_CashFlowsFromUsedInOperatingActivitiesDiscontinuedOperations" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CashFlowsFromUsedInInvestingActivities" xlink:label="ifrs-full_CashFlowsFromUsedInInvestingActivities" xlink:title="ifrs-full_CashFlowsFromUsedInInvestingActivities" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CashFlowsFromUsedInInvestingActivitiesContinuingOperations" xlink:label="ifrs-full_CashFlowsFromUsedInInvestingActivitiesContinuingOperations" xlink:title="ifrs-full_CashFlowsFromUsedInInvestingActivitiesContinuingOperations" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInInvestingActivities" xlink:to="ifrs-full_CashFlowsFromUsedInInvestingActivitiesContinuingOperations" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInInvestingActivities to ifrs-full_CashFlowsFromUsedInInvestingActivitiesContinuingOperations" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_FinancialInvestmentsNetOfRedemptions" xlink:label="ugp_FinancialInvestmentsNetOfRedemptions" xlink:title="ugp_FinancialInvestmentsNetOfRedemptions" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInInvestingActivitiesContinuingOperations" xlink:to="ugp_FinancialInvestmentsNetOfRedemptions" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInInvestingActivitiesContinuingOperations to ugp_FinancialInvestmentsNetOfRedemptions" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_PurchaseOfPropertyPlantAndEquipmentAndIntangibleAssetsClassifiedAsInvestingActivities" xlink:label="ugp_PurchaseOfPropertyPlantAndEquipmentAndIntangibleAssetsClassifiedAsInvestingActivities" xlink:title="ugp_PurchaseOfPropertyPlantAndEquipmentAndIntangibleAssetsClassifiedAsInvestingActivities" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInInvestingActivitiesContinuingOperations" xlink:to="ugp_PurchaseOfPropertyPlantAndEquipmentAndIntangibleAssetsClassifiedAsInvestingActivities" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInInvestingActivitiesContinuingOperations to ugp_PurchaseOfPropertyPlantAndEquipmentAndIntangibleAssetsClassifiedAsInvestingActivities" order="1" weight="-1" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_CashReceiptsFromRepaymentOfLoansMadeToRelatedParties" xlink:label="ugp_CashReceiptsFromRepaymentOfLoansMadeToRelatedParties" xlink:title="ugp_CashReceiptsFromRepaymentOfLoansMadeToRelatedParties" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInInvestingActivitiesContinuingOperations" xlink:to="ugp_CashReceiptsFromRepaymentOfLoansMadeToRelatedParties" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInInvestingActivitiesContinuingOperations to ugp_CashReceiptsFromRepaymentOfLoansMadeToRelatedParties" order="2" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_ProceedsFromDisposalOfInvestmentsAndPropertyPlantAndEquipmentClassifiedAsInvestingActivities" xlink:label="ugp_ProceedsFromDisposalOfInvestmentsAndPropertyPlantAndEquipmentClassifiedAsInvestingActivities" xlink:title="ugp_ProceedsFromDisposalOfInvestmentsAndPropertyPlantAndEquipmentClassifiedAsInvestingActivities" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInInvestingActivitiesContinuingOperations" xlink:to="ugp_ProceedsFromDisposalOfInvestmentsAndPropertyPlantAndEquipmentClassifiedAsInvestingActivities" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInInvestingActivitiesContinuingOperations to ugp_ProceedsFromDisposalOfInvestmentsAndPropertyPlantAndEquipmentClassifiedAsInvestingActivities" order="3" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_OtherCashPaymentsToAcquireInterestsInJointVenturesClassifiedAsInvestingActivities" xlink:label="ifrs-full_OtherCashPaymentsToAcquireInterestsInJointVenturesClassifiedAsInvestingActivities" xlink:title="ifrs-full_OtherCashPaymentsToAcquireInterestsInJointVenturesClassifiedAsInvestingActivities" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInInvestingActivitiesContinuingOperations" xlink:to="ifrs-full_OtherCashPaymentsToAcquireInterestsInJointVenturesClassifiedAsInvestingActivities" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInInvestingActivitiesContinuingOperations to ifrs-full_OtherCashPaymentsToAcquireInterestsInJointVenturesClassifiedAsInvestingActivities" order="4" weight="-1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_OtherCashReceiptsFromSalesOfInterestsInJointVenturesClassifiedAsInvestingActivities" xlink:label="ifrs-full_OtherCashReceiptsFromSalesOfInterestsInJointVenturesClassifiedAsInvestingActivities" xlink:title="ifrs-full_OtherCashReceiptsFromSalesOfInterestsInJointVenturesClassifiedAsInvestingActivities" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInInvestingActivitiesContinuingOperations" xlink:to="ifrs-full_OtherCashReceiptsFromSalesOfInterestsInJointVenturesClassifiedAsInvestingActivities" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInInvestingActivitiesContinuingOperations to ifrs-full_OtherCashReceiptsFromSalesOfInterestsInJointVenturesClassifiedAsInvestingActivities" order="5" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_NetCashConsumedInPurchaseOfinvestmentsSaleTransactionAndOtherAssets" xlink:label="ugp_NetCashConsumedInPurchaseOfinvestmentsSaleTransactionAndOtherAssets" xlink:title="ugp_NetCashConsumedInPurchaseOfinvestmentsSaleTransactionAndOtherAssets" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInInvestingActivitiesContinuingOperations" xlink:to="ugp_NetCashConsumedInPurchaseOfinvestmentsSaleTransactionAndOtherAssets" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInInvestingActivitiesContinuingOperations to ugp_NetCashConsumedInPurchaseOfinvestmentsSaleTransactionAndOtherAssets" order="6" weight="-1" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CashFlowsFromUsedInInvestingActivitiesDiscontinuedOperations" xlink:label="ifrs-full_CashFlowsFromUsedInInvestingActivitiesDiscontinuedOperations" xlink:title="ifrs-full_CashFlowsFromUsedInInvestingActivitiesDiscontinuedOperations" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInInvestingActivities" xlink:to="ifrs-full_CashFlowsFromUsedInInvestingActivitiesDiscontinuedOperations" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInInvestingActivities to ifrs-full_CashFlowsFromUsedInInvestingActivitiesDiscontinuedOperations" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CashFlowsFromUsedInFinancingActivities" xlink:label="ifrs-full_CashFlowsFromUsedInFinancingActivities" xlink:title="ifrs-full_CashFlowsFromUsedInFinancingActivities" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CashFlowsFromUsedInFinancingActivitiesContinuingOperations" xlink:label="ifrs-full_CashFlowsFromUsedInFinancingActivitiesContinuingOperations" xlink:title="ifrs-full_CashFlowsFromUsedInFinancingActivitiesContinuingOperations" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInFinancingActivities" xlink:to="ifrs-full_CashFlowsFromUsedInFinancingActivitiesContinuingOperations" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInFinancingActivities to ifrs-full_CashFlowsFromUsedInFinancingActivitiesContinuingOperations" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ProceedsFromBorrowingsClassifiedAsFinancingActivities" xlink:label="ifrs-full_ProceedsFromBorrowingsClassifiedAsFinancingActivities" xlink:title="ifrs-full_ProceedsFromBorrowingsClassifiedAsFinancingActivities" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInFinancingActivitiesContinuingOperations" xlink:to="ifrs-full_ProceedsFromBorrowingsClassifiedAsFinancingActivities" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInFinancingActivitiesContinuingOperations to ifrs-full_ProceedsFromBorrowingsClassifiedAsFinancingActivities" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_RepaymentsOfBorrowingsClassifiedAsFinancingActivities" xlink:label="ifrs-full_RepaymentsOfBorrowingsClassifiedAsFinancingActivities" xlink:title="ifrs-full_RepaymentsOfBorrowingsClassifiedAsFinancingActivities" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInFinancingActivitiesContinuingOperations" xlink:to="ifrs-full_RepaymentsOfBorrowingsClassifiedAsFinancingActivities" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInFinancingActivitiesContinuingOperations to ifrs-full_RepaymentsOfBorrowingsClassifiedAsFinancingActivities" order="1" weight="-1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_InterestPaidForBorrowingsClassifiedAsFinancingActivities" xlink:label="ugp_InterestPaidForBorrowingsClassifiedAsFinancingActivities" xlink:title="ugp_InterestPaidForBorrowingsClassifiedAsFinancingActivities" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInFinancingActivitiesContinuingOperations" xlink:to="ugp_InterestPaidForBorrowingsClassifiedAsFinancingActivities" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInFinancingActivitiesContinuingOperations to ugp_InterestPaidForBorrowingsClassifiedAsFinancingActivities" order="2" weight="-1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_PaymentsOfLeaseLiabilitiesClassifiedAsFinancingActivities" xlink:label="ifrs-full_PaymentsOfLeaseLiabilitiesClassifiedAsFinancingActivities" xlink:title="ifrs-full_PaymentsOfLeaseLiabilitiesClassifiedAsFinancingActivities" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInFinancingActivitiesContinuingOperations" xlink:to="ifrs-full_PaymentsOfLeaseLiabilitiesClassifiedAsFinancingActivities" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInFinancingActivitiesContinuingOperations to ifrs-full_PaymentsOfLeaseLiabilitiesClassifiedAsFinancingActivities" order="3" weight="-1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_InterestPaidForLeaseLiabilitiesClassifiedAsFinancingActivities" xlink:label="ugp_InterestPaidForLeaseLiabilitiesClassifiedAsFinancingActivities" xlink:title="ugp_InterestPaidForLeaseLiabilitiesClassifiedAsFinancingActivities" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInFinancingActivitiesContinuingOperations" xlink:to="ugp_InterestPaidForLeaseLiabilitiesClassifiedAsFinancingActivities" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInFinancingActivitiesContinuingOperations to ugp_InterestPaidForLeaseLiabilitiesClassifiedAsFinancingActivities" order="4" weight="-1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_DividendsPaidClassifiedAsFinancingActivities" xlink:label="ifrs-full_DividendsPaidClassifiedAsFinancingActivities" xlink:title="ifrs-full_DividendsPaidClassifiedAsFinancingActivities" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInFinancingActivitiesContinuingOperations" xlink:to="ifrs-full_DividendsPaidClassifiedAsFinancingActivities" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInFinancingActivitiesContinuingOperations to ifrs-full_DividendsPaidClassifiedAsFinancingActivities" order="5" weight="-1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_ProceedsFromFinancialLiabilitiesOfCustomersClassifiedAsFinancingActivities" xlink:label="ugp_ProceedsFromFinancialLiabilitiesOfCustomersClassifiedAsFinancingActivities" xlink:title="ugp_ProceedsFromFinancialLiabilitiesOfCustomersClassifiedAsFinancingActivities" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInFinancingActivitiesContinuingOperations" xlink:to="ugp_ProceedsFromFinancialLiabilitiesOfCustomersClassifiedAsFinancingActivities" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInFinancingActivitiesContinuingOperations to ugp_ProceedsFromFinancialLiabilitiesOfCustomersClassifiedAsFinancingActivities" order="6" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_PaymentsOfFinancialLiabilitiesOfCustomersClassifiedAsFinancingActivities" xlink:label="ugp_PaymentsOfFinancialLiabilitiesOfCustomersClassifiedAsFinancingActivities" xlink:title="ugp_PaymentsOfFinancialLiabilitiesOfCustomersClassifiedAsFinancingActivities" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInFinancingActivitiesContinuingOperations" xlink:to="ugp_PaymentsOfFinancialLiabilitiesOfCustomersClassifiedAsFinancingActivities" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInFinancingActivitiesContinuingOperations to ugp_PaymentsOfFinancialLiabilitiesOfCustomersClassifiedAsFinancingActivities" order="7" weight="-1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ProceedsFromContributionsOfNoncontrollingInterests" xlink:label="ifrs-full_ProceedsFromContributionsOfNoncontrollingInterests" xlink:title="ifrs-full_ProceedsFromContributionsOfNoncontrollingInterests" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInFinancingActivitiesContinuingOperations" xlink:to="ifrs-full_ProceedsFromContributionsOfNoncontrollingInterests" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInFinancingActivitiesContinuingOperations to ifrs-full_ProceedsFromContributionsOfNoncontrollingInterests" order="8" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_RepurchaseOfTreasuryShares" xlink:label="ugp_RepurchaseOfTreasuryShares" xlink:title="ugp_RepurchaseOfTreasuryShares" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInFinancingActivitiesContinuingOperations" xlink:to="ugp_RepurchaseOfTreasuryShares" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInFinancingActivitiesContinuingOperations to ugp_RepurchaseOfTreasuryShares" order="9" weight="-1" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CashRepaymentsOfAdvancesAndLoansFromRelatedParties" xlink:label="ifrs-full_CashRepaymentsOfAdvancesAndLoansFromRelatedParties" xlink:title="ifrs-full_CashRepaymentsOfAdvancesAndLoansFromRelatedParties" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInFinancingActivitiesContinuingOperations" xlink:to="ifrs-full_CashRepaymentsOfAdvancesAndLoansFromRelatedParties" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInFinancingActivitiesContinuingOperations to ifrs-full_CashRepaymentsOfAdvancesAndLoansFromRelatedParties" order="10" weight="-1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CashFlowsFromUsedInFinancingActivitiesDiscontinuedOperations" xlink:label="ifrs-full_CashFlowsFromUsedInFinancingActivitiesDiscontinuedOperations" xlink:title="ifrs-full_CashFlowsFromUsedInFinancingActivitiesDiscontinuedOperations" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsFromUsedInFinancingActivities" xlink:to="ifrs-full_CashFlowsFromUsedInFinancingActivitiesDiscontinuedOperations" xlink:title="Calculation : ifrs-full_CashFlowsFromUsedInFinancingActivities to ifrs-full_CashFlowsFromUsedInFinancingActivitiesDiscontinuedOperations" order="1" weight="1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/SegmentinformationFinancialInformationofSegmentsDetail">
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_DepreciationAmortisationAndImpairmentLossReversalOfImpairmentLossRecognisedInProfitOrLoss" xlink:label="ifrs-full_DepreciationAmortisationAndImpairmentLossReversalOfImpairmentLossRecognisedInProfitOrLoss" xlink:title="ifrs-full_DepreciationAmortisationAndImpairmentLossReversalOfImpairmentLossRecognisedInProfitOrLoss" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_DepreciationAndAmortisationExpense" xlink:label="ifrs-full_DepreciationAndAmortisationExpense" xlink:title="ifrs-full_DepreciationAndAmortisationExpense" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_DepreciationAmortisationAndImpairmentLossReversalOfImpairmentLossRecognisedInProfitOrLoss" xlink:to="ifrs-full_DepreciationAndAmortisationExpense" xlink:title="Calculation : ifrs-full_DepreciationAmortisationAndImpairmentLossReversalOfImpairmentLossRecognisedInProfitOrLoss to ifrs-full_DepreciationAndAmortisationExpense" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_AmortisationAssetsRecognisedFromCostsIncurredToObtainOrFulfilContractsWithCustomers" xlink:label="ifrs-full_AmortisationAssetsRecognisedFromCostsIncurredToObtainOrFulfilContractsWithCustomers" xlink:title="ifrs-full_AmortisationAssetsRecognisedFromCostsIncurredToObtainOrFulfilContractsWithCustomers" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_DepreciationAmortisationAndImpairmentLossReversalOfImpairmentLossRecognisedInProfitOrLoss" xlink:to="ifrs-full_AmortisationAssetsRecognisedFromCostsIncurredToObtainOrFulfilContractsWithCustomers" xlink:title="Calculation : ifrs-full_DepreciationAmortisationAndImpairmentLossReversalOfImpairmentLossRecognisedInProfitOrLoss to ifrs-full_AmortisationAssetsRecognisedFromCostsIncurredToObtainOrFulfilContractsWithCustomers" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_AmortizationOfRightToUseAsset" xlink:label="ugp_AmortizationOfRightToUseAsset" xlink:title="ugp_AmortizationOfRightToUseAsset" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_DepreciationAmortisationAndImpairmentLossReversalOfImpairmentLossRecognisedInProfitOrLoss" xlink:to="ugp_AmortizationOfRightToUseAsset" xlink:title="Calculation : ifrs-full_DepreciationAmortisationAndImpairmentLossReversalOfImpairmentLossRecognisedInProfitOrLoss to ugp_AmortizationOfRightToUseAsset" order="2" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_AmortizationOfFairValueAdjustmentOnInvestmentAccountedForUsingEquityMethod" xlink:label="ugp_AmortizationOfFairValueAdjustmentOnInvestmentAccountedForUsingEquityMethod" xlink:title="ugp_AmortizationOfFairValueAdjustmentOnInvestmentAccountedForUsingEquityMethod" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_DepreciationAmortisationAndImpairmentLossReversalOfImpairmentLossRecognisedInProfitOrLoss" xlink:to="ugp_AmortizationOfFairValueAdjustmentOnInvestmentAccountedForUsingEquityMethod" xlink:title="Calculation : ifrs-full_DepreciationAmortisationAndImpairmentLossReversalOfImpairmentLossRecognisedInProfitOrLoss to ugp_AmortizationOfFairValueAdjustmentOnInvestmentAccountedForUsingEquityMethod" order="3" weight="1" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndShareOfProfitLossOfJointVenturesAndAssociates" xlink:label="ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndShareOfProfitLossOfJointVenturesAndAssociates" xlink:title="ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndShareOfProfitLossOfJointVenturesAndAssociates" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_GrossProfit" xlink:label="ifrs-full_GrossProfit" xlink:title="ifrs-full_GrossProfit" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndShareOfProfitLossOfJointVenturesAndAssociates" xlink:to="ifrs-full_GrossProfit" xlink:title="Calculation : ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndShareOfProfitLossOfJointVenturesAndAssociates to ifrs-full_GrossProfit" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_SellingAndMarketingExpenses" xlink:label="ugp_SellingAndMarketingExpenses" xlink:title="ugp_SellingAndMarketingExpenses" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndShareOfProfitLossOfJointVenturesAndAssociates" xlink:to="ugp_SellingAndMarketingExpenses" xlink:title="Calculation : ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndShareOfProfitLossOfJointVenturesAndAssociates to ugp_SellingAndMarketingExpenses" order="1" weight="-1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ImpairmentLossReversalOfImpairmentLossRecognisedInProfitOrLossTradeReceivables" xlink:label="ifrs-full_ImpairmentLossReversalOfImpairmentLossRecognisedInProfitOrLossTradeReceivables" xlink:title="ifrs-full_ImpairmentLossReversalOfImpairmentLossRecognisedInProfitOrLossTradeReceivables" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndShareOfProfitLossOfJointVenturesAndAssociates" xlink:to="ifrs-full_ImpairmentLossReversalOfImpairmentLossRecognisedInProfitOrLossTradeReceivables" xlink:title="Calculation : ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndShareOfProfitLossOfJointVenturesAndAssociates to ifrs-full_ImpairmentLossReversalOfImpairmentLossRecognisedInProfitOrLossTradeReceivables" order="2" weight="-1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_GeneralAndAdministrativeExpense" xlink:label="ifrs-full_GeneralAndAdministrativeExpense" xlink:title="ifrs-full_GeneralAndAdministrativeExpense" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndShareOfProfitLossOfJointVenturesAndAssociates" xlink:to="ifrs-full_GeneralAndAdministrativeExpense" xlink:title="Calculation : ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndShareOfProfitLossOfJointVenturesAndAssociates to ifrs-full_GeneralAndAdministrativeExpense" order="3" weight="-1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_GainsLossesOnDisposalsOfNoncurrentAssets" xlink:label="ifrs-full_GainsLossesOnDisposalsOfNoncurrentAssets" xlink:title="ifrs-full_GainsLossesOnDisposalsOfNoncurrentAssets" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndShareOfProfitLossOfJointVenturesAndAssociates" xlink:to="ifrs-full_GainsLossesOnDisposalsOfNoncurrentAssets" xlink:title="Calculation : ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndShareOfProfitLossOfJointVenturesAndAssociates to ifrs-full_GainsLossesOnDisposalsOfNoncurrentAssets" order="4" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_OtherOperatingIncomeExpense" xlink:label="ifrs-full_OtherOperatingIncomeExpense" xlink:title="ifrs-full_OtherOperatingIncomeExpense" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndShareOfProfitLossOfJointVenturesAndAssociates" xlink:to="ifrs-full_OtherOperatingIncomeExpense" xlink:title="Calculation : ugp_OperatingIncomeBeforeFinancialIncomeExpensesAndShareOfProfitLossOfJointVenturesAndAssociates to ifrs-full_OtherOperatingIncomeExpense" order="5" weight="1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/FinancialresultFinancialresultDetail">
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_FinanceIncome" xlink:label="ifrs-full_FinanceIncome" xlink:title="ifrs-full_FinanceIncome" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_FinancialInvestmentsInterest" xlink:label="ugp_FinancialInvestmentsInterest" xlink:title="ugp_FinancialInvestmentsInterest" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_FinanceIncome" xlink:to="ugp_FinancialInvestmentsInterest" xlink:title="Calculation : ifrs-full_FinanceIncome to ugp_FinancialInvestmentsInterest" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_ChangesInSubscriptionWarrantsIncome" xlink:label="ugp_ChangesInSubscriptionWarrantsIncome" xlink:title="ugp_ChangesInSubscriptionWarrantsIncome" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_FinanceIncome" xlink:to="ugp_ChangesInSubscriptionWarrantsIncome" xlink:title="Calculation : ifrs-full_FinanceIncome to ugp_ChangesInSubscriptionWarrantsIncome" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_SelicInterestOnPISAndCOFINSCredits" xlink:label="ugp_SelicInterestOnPISAndCOFINSCredits" xlink:title="ugp_SelicInterestOnPISAndCOFINSCredits" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_FinanceIncome" xlink:to="ugp_SelicInterestOnPISAndCOFINSCredits" xlink:title="Calculation : ifrs-full_FinanceIncome to ugp_SelicInterestOnPISAndCOFINSCredits" order="2" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_OtherFinanceIncome" xlink:label="ifrs-full_OtherFinanceIncome" xlink:title="ifrs-full_OtherFinanceIncome" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_FinanceIncome" xlink:to="ifrs-full_OtherFinanceIncome" xlink:title="Calculation : ifrs-full_FinanceIncome to ifrs-full_OtherFinanceIncome" order="3" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_UpdateOfProvisionsAndOtherIncome" xlink:label="ugp_UpdateOfProvisionsAndOtherIncome" xlink:title="ugp_UpdateOfProvisionsAndOtherIncome" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_FinanceIncome" xlink:to="ugp_UpdateOfProvisionsAndOtherIncome" xlink:title="Calculation : ifrs-full_FinanceIncome to ugp_UpdateOfProvisionsAndOtherIncome" order="4" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_InterestIncomeOnLoansAndAdvancesToCustomers" xlink:label="ifrs-full_InterestIncomeOnLoansAndAdvancesToCustomers" xlink:title="ifrs-full_InterestIncomeOnLoansAndAdvancesToCustomers" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_FinanceIncome" xlink:to="ifrs-full_InterestIncomeOnLoansAndAdvancesToCustomers" xlink:title="Calculation : ifrs-full_FinanceIncome to ifrs-full_InterestIncomeOnLoansAndAdvancesToCustomers" order="5" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_FinanceCosts" xlink:label="ifrs-full_FinanceCosts" xlink:title="ifrs-full_FinanceCosts" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_FinanceLeasesInterest" xlink:label="ugp_FinanceLeasesInterest" xlink:title="ugp_FinanceLeasesInterest" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_FinanceCosts" xlink:to="ugp_FinanceLeasesInterest" xlink:title="Calculation : ifrs-full_FinanceCosts to ugp_FinanceLeasesInterest" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_ExchangeVariationNetOfGainsAndLossesHedgingInstruments" xlink:label="ugp_ExchangeVariationNetOfGainsAndLossesHedgingInstruments" xlink:title="ugp_ExchangeVariationNetOfGainsAndLossesHedgingInstruments" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_FinanceCosts" xlink:to="ugp_ExchangeVariationNetOfGainsAndLossesHedgingInstruments" xlink:title="Calculation : ifrs-full_FinanceCosts to ugp_ExchangeVariationNetOfGainsAndLossesHedgingInstruments" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_ChangesInSubscriptionWarrants" xlink:label="ugp_ChangesInSubscriptionWarrants" xlink:title="ugp_ChangesInSubscriptionWarrants" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_FinanceCosts" xlink:to="ugp_ChangesInSubscriptionWarrants" xlink:title="Calculation : ifrs-full_FinanceCosts to ugp_ChangesInSubscriptionWarrants" order="2" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_OtherFinanceCost" xlink:label="ifrs-full_OtherFinanceCost" xlink:title="ifrs-full_OtherFinanceCost" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_FinanceCosts" xlink:to="ifrs-full_OtherFinanceCost" xlink:title="Calculation : ifrs-full_FinanceCosts to ifrs-full_OtherFinanceCost" order="3" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_InterestExpenseOnBorrowings" xlink:label="ifrs-full_InterestExpenseOnBorrowings" xlink:title="ifrs-full_InterestExpenseOnBorrowings" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_FinanceCosts" xlink:to="ifrs-full_InterestExpenseOnBorrowings" xlink:title="Calculation : ifrs-full_FinanceCosts to ifrs-full_InterestExpenseOnBorrowings" order="4" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_InterestExpenseOnDebtInstrumentsIssued" xlink:label="ifrs-full_InterestExpenseOnDebtInstrumentsIssued" xlink:title="ifrs-full_InterestExpenseOnDebtInstrumentsIssued" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_FinanceCosts" xlink:to="ifrs-full_InterestExpenseOnDebtInstrumentsIssued" xlink:title="Calculation : ifrs-full_FinanceCosts to ifrs-full_InterestExpenseOnDebtInstrumentsIssued" order="5" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_InterestExpenseOnOtherFinancialLiabilities" xlink:label="ifrs-full_InterestExpenseOnOtherFinancialLiabilities" xlink:title="ifrs-full_InterestExpenseOnOtherFinancialLiabilities" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_FinanceCosts" xlink:to="ifrs-full_InterestExpenseOnOtherFinancialLiabilities" xlink:title="Calculation : ifrs-full_FinanceCosts to ifrs-full_InterestExpenseOnOtherFinancialLiabilities" order="6" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_UpdateOfProvisionsNetAndOtherExpenses" xlink:label="ugp_UpdateOfProvisionsNetAndOtherExpenses" xlink:title="ugp_UpdateOfProvisionsNetAndOtherExpenses" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_FinanceCosts" xlink:to="ugp_UpdateOfProvisionsNetAndOtherExpenses" xlink:title="Calculation : ifrs-full_FinanceCosts to ugp_UpdateOfProvisionsNetAndOtherExpenses" order="7" weight="1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/CostsexpensesandotheroperatingresultsbynatureCostsandexpensesbynatureDetail">
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ExpenseByNature" xlink:label="ifrs-full_ExpenseByNature" xlink:title="ifrs-full_ExpenseByNature" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_RawMaterialsAndConsumablesUsed" xlink:label="ifrs-full_RawMaterialsAndConsumablesUsed" xlink:title="ifrs-full_RawMaterialsAndConsumablesUsed" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ExpenseByNature" xlink:to="ifrs-full_RawMaterialsAndConsumablesUsed" xlink:title="Calculation : ifrs-full_ExpenseByNature to ifrs-full_RawMaterialsAndConsumablesUsed" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_EmployeeBenefitsExpense" xlink:label="ifrs-full_EmployeeBenefitsExpense" xlink:title="ifrs-full_EmployeeBenefitsExpense" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ExpenseByNature" xlink:to="ifrs-full_EmployeeBenefitsExpense" xlink:title="Calculation : ifrs-full_ExpenseByNature to ifrs-full_EmployeeBenefitsExpense" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_FreightAndStorageExpense" xlink:label="ugp_FreightAndStorageExpense" xlink:title="ugp_FreightAndStorageExpense" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ExpenseByNature" xlink:to="ugp_FreightAndStorageExpense" xlink:title="Calculation : ifrs-full_ExpenseByNature to ugp_FreightAndStorageExpense" order="2" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_DepreciationAndAmortizationIncludingPisAndCofinsTaxes" xlink:label="ugp_DepreciationAndAmortizationIncludingPisAndCofinsTaxes" xlink:title="ugp_DepreciationAndAmortizationIncludingPisAndCofinsTaxes" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ExpenseByNature" xlink:to="ugp_DepreciationAndAmortizationIncludingPisAndCofinsTaxes" xlink:title="Calculation : ifrs-full_ExpenseByNature to ugp_DepreciationAndAmortizationIncludingPisAndCofinsTaxes" order="3" weight="1" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_AmortizationOfRightToUseAsset" xlink:label="ugp_AmortizationOfRightToUseAsset" xlink:title="ugp_AmortizationOfRightToUseAsset" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ExpenseByNature" xlink:to="ugp_AmortizationOfRightToUseAsset" xlink:title="Calculation : ifrs-full_ExpenseByNature to ugp_AmortizationOfRightToUseAsset" order="4" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_AdvertisingAndMarketingExpense" xlink:label="ugp_AdvertisingAndMarketingExpense" xlink:title="ugp_AdvertisingAndMarketingExpense" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ExpenseByNature" xlink:to="ugp_AdvertisingAndMarketingExpense" xlink:title="Calculation : ifrs-full_ExpenseByNature to ugp_AdvertisingAndMarketingExpense" order="5" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ServicesExpense" xlink:label="ifrs-full_ServicesExpense" xlink:title="ifrs-full_ServicesExpense" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ExpenseByNature" xlink:to="ifrs-full_ServicesExpense" xlink:title="Calculation : ifrs-full_ExpenseByNature to ifrs-full_ServicesExpense" order="6" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_ExpensesFromDecarbonizationObligation" xlink:label="ugp_ExpensesFromDecarbonizationObligation" xlink:title="ugp_ExpensesFromDecarbonizationObligation" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ExpenseByNature" xlink:to="ugp_ExpensesFromDecarbonizationObligation" xlink:title="Calculation : ifrs-full_ExpenseByNature to ugp_ExpensesFromDecarbonizationObligation" order="7" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_ExtemporaneousTaxCredits" xlink:label="ugp_ExtemporaneousTaxCredits" xlink:title="ugp_ExtemporaneousTaxCredits" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ExpenseByNature" xlink:to="ugp_ExtemporaneousTaxCredits" xlink:title="Calculation : ifrs-full_ExpenseByNature to ugp_ExtemporaneousTaxCredits" order="8" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_OtherOperatingIncomeExpenseByFunction" xlink:label="ugp_OtherOperatingIncomeExpenseByFunction" xlink:title="ugp_OtherOperatingIncomeExpenseByFunction" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ExpenseByNature" xlink:to="ugp_OtherOperatingIncomeExpenseByFunction" xlink:title="Calculation : ifrs-full_ExpenseByNature to ugp_OtherOperatingIncomeExpenseByFunction" order="9" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_SscOrHoldingExpenses" xlink:label="ugp_SscOrHoldingExpenses" xlink:title="ugp_SscOrHoldingExpenses" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ExpenseByNature" xlink:to="ugp_SscOrHoldingExpenses" xlink:title="Calculation : ifrs-full_ExpenseByNature to ugp_SscOrHoldingExpenses" order="10" weight="1" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/AcquisitionofInterestandControlScheduleoftransactionamountsforacquiringaninterestDetails">
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_GoodwillRecognisedAsOfAcquisitionDate" xlink:label="ifrs-full_GoodwillRecognisedAsOfAcquisitionDate" xlink:title="ifrs-full_GoodwillRecognisedAsOfAcquisitionDate" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_InvestmentAccountedForUsingEquityMethod" xlink:label="ifrs-full_InvestmentAccountedForUsingEquityMethod" xlink:title="ifrs-full_InvestmentAccountedForUsingEquityMethod" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_GoodwillRecognisedAsOfAcquisitionDate" xlink:to="ifrs-full_InvestmentAccountedForUsingEquityMethod" xlink:title="Calculation : ifrs-full_GoodwillRecognisedAsOfAcquisitionDate to ifrs-full_InvestmentAccountedForUsingEquityMethod" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_IdentifiableIntangibleAssetsRecognisedAsOfAcquisitionDate" xlink:label="ifrs-full_IdentifiableIntangibleAssetsRecognisedAsOfAcquisitionDate" xlink:title="ifrs-full_IdentifiableIntangibleAssetsRecognisedAsOfAcquisitionDate" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_InvestmentAccountedForUsingEquityMethod" xlink:to="ifrs-full_IdentifiableIntangibleAssetsRecognisedAsOfAcquisitionDate" xlink:title="Calculation : ifrs-full_InvestmentAccountedForUsingEquityMethod to ifrs-full_IdentifiableIntangibleAssetsRecognisedAsOfAcquisitionDate" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_FinancialAssetsRecognisedAsOfAcquisitionDate" xlink:label="ifrs-full_FinancialAssetsRecognisedAsOfAcquisitionDate" xlink:title="ifrs-full_FinancialAssetsRecognisedAsOfAcquisitionDate" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_IdentifiableIntangibleAssetsRecognisedAsOfAcquisitionDate" xlink:to="ifrs-full_FinancialAssetsRecognisedAsOfAcquisitionDate" xlink:title="Calculation : ifrs-full_IdentifiableIntangibleAssetsRecognisedAsOfAcquisitionDate to ifrs-full_FinancialAssetsRecognisedAsOfAcquisitionDate" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_FinancialAssetsAtFairValueThroughProfitOrLoss" xlink:label="ifrs-full_FinancialAssetsAtFairValueThroughProfitOrLoss" xlink:title="ifrs-full_FinancialAssetsAtFairValueThroughProfitOrLoss" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_IdentifiableIntangibleAssetsRecognisedAsOfAcquisitionDate" xlink:to="ifrs-full_FinancialAssetsAtFairValueThroughProfitOrLoss" xlink:title="Calculation : ifrs-full_IdentifiableIntangibleAssetsRecognisedAsOfAcquisitionDate to ifrs-full_FinancialAssetsAtFairValueThroughProfitOrLoss" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_SubsequentAcquisitionsOfAdditionalInterests" xlink:label="ugp_SubsequentAcquisitionsOfAdditionalInterests" xlink:title="ugp_SubsequentAcquisitionsOfAdditionalInterests" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_InvestmentAccountedForUsingEquityMethod" xlink:to="ugp_SubsequentAcquisitionsOfAdditionalInterests" xlink:title="Calculation : ifrs-full_InvestmentAccountedForUsingEquityMethod to ugp_SubsequentAcquisitionsOfAdditionalInterests" order="1" weight="1" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_AcquisitiondateFairValueOfEquityInterestInAcquireeHeldByAcquirerImmediatelyBeforeAcquisitionDate" xlink:label="ifrs-full_AcquisitiondateFairValueOfEquityInterestInAcquireeHeldByAcquirerImmediatelyBeforeAcquisitionDate" xlink:title="ifrs-full_AcquisitiondateFairValueOfEquityInterestInAcquireeHeldByAcquirerImmediatelyBeforeAcquisitionDate" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_GoodwillRecognisedAsOfAcquisitionDate" xlink:to="ifrs-full_AcquisitiondateFairValueOfEquityInterestInAcquireeHeldByAcquirerImmediatelyBeforeAcquisitionDate" xlink:title="Calculation : ifrs-full_GoodwillRecognisedAsOfAcquisitionDate to ifrs-full_AcquisitiondateFairValueOfEquityInterestInAcquireeHeldByAcquirerImmediatelyBeforeAcquisitionDate" order="1" weight="-1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/AcquisitionofInterestandControlScheduleoftheprovisionalbalancesofassetsacquiredandliabilitiesassumedontheacquisitiondateDetails">
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_AcquisitiondateFairValueOfTotalConsiderationTransferred" xlink:label="ifrs-full_AcquisitiondateFairValueOfTotalConsiderationTransferred" xlink:title="ifrs-full_AcquisitiondateFairValueOfTotalConsiderationTransferred" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CashTransferred" xlink:label="ifrs-full_CashTransferred" xlink:title="ifrs-full_CashTransferred" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_AcquisitiondateFairValueOfTotalConsiderationTransferred" xlink:to="ifrs-full_CashTransferred" xlink:title="Calculation : ifrs-full_AcquisitiondateFairValueOfTotalConsiderationTransferred to ifrs-full_CashTransferred" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ContingentConsiderationRecognisedAsOfAcquisitionDate" xlink:label="ifrs-full_ContingentConsiderationRecognisedAsOfAcquisitionDate" xlink:title="ifrs-full_ContingentConsiderationRecognisedAsOfAcquisitionDate" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_AcquisitiondateFairValueOfTotalConsiderationTransferred" xlink:to="ifrs-full_ContingentConsiderationRecognisedAsOfAcquisitionDate" xlink:title="Calculation : ifrs-full_AcquisitiondateFairValueOfTotalConsiderationTransferred to ifrs-full_ContingentConsiderationRecognisedAsOfAcquisitionDate" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_NoncontrollingInterestsOfAcquirer" xlink:label="ugp_NoncontrollingInterestsOfAcquirer" xlink:title="ugp_NoncontrollingInterestsOfAcquirer" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_AcquisitiondateFairValueOfTotalConsiderationTransferred" xlink:to="ugp_NoncontrollingInterestsOfAcquirer" xlink:title="Calculation : ifrs-full_AcquisitiondateFairValueOfTotalConsiderationTransferred to ugp_NoncontrollingInterestsOfAcquirer" order="2" weight="1" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CashFlowsUsedInObtainingControlOfSubsidiariesOrOtherBusinessesClassifiedAsInvestingActivities" xlink:label="ifrs-full_CashFlowsUsedInObtainingControlOfSubsidiariesOrOtherBusinessesClassifiedAsInvestingActivities" xlink:title="ifrs-full_CashFlowsUsedInObtainingControlOfSubsidiariesOrOtherBusinessesClassifiedAsInvestingActivities" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_PortionOfInitialConsiderationPaidConsistingOfCashAndCashEquivalents" xlink:label="ugp_PortionOfInitialConsiderationPaidConsistingOfCashAndCashEquivalents" xlink:title="ugp_PortionOfInitialConsiderationPaidConsistingOfCashAndCashEquivalents" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsUsedInObtainingControlOfSubsidiariesOrOtherBusinessesClassifiedAsInvestingActivities" xlink:to="ugp_PortionOfInitialConsiderationPaidConsistingOfCashAndCashEquivalents" xlink:title="Calculation : ifrs-full_CashFlowsUsedInObtainingControlOfSubsidiariesOrOtherBusinessesClassifiedAsInvestingActivities to ugp_PortionOfInitialConsiderationPaidConsistingOfCashAndCashEquivalents" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_PortionOfConsiderationPaidReceivedConsistingOfCashAndCashEquivalents" xlink:label="ifrs-full_PortionOfConsiderationPaidReceivedConsistingOfCashAndCashEquivalents" xlink:title="ifrs-full_PortionOfConsiderationPaidReceivedConsistingOfCashAndCashEquivalents" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsUsedInObtainingControlOfSubsidiariesOrOtherBusinessesClassifiedAsInvestingActivities" xlink:to="ifrs-full_PortionOfConsiderationPaidReceivedConsistingOfCashAndCashEquivalents" xlink:title="Calculation : ifrs-full_CashFlowsUsedInObtainingControlOfSubsidiariesOrOtherBusinessesClassifiedAsInvestingActivities to ifrs-full_PortionOfConsiderationPaidReceivedConsistingOfCashAndCashEquivalents" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_PortionOfSubsequentConsiderationPaidConsistingOfCashAndCashEquivalents" xlink:label="ugp_PortionOfSubsequentConsiderationPaidConsistingOfCashAndCashEquivalents" xlink:title="ugp_PortionOfSubsequentConsiderationPaidConsistingOfCashAndCashEquivalents" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsUsedInObtainingControlOfSubsidiariesOrOtherBusinessesClassifiedAsInvestingActivities" xlink:to="ugp_PortionOfSubsequentConsiderationPaidConsistingOfCashAndCashEquivalents" xlink:title="Calculation : ifrs-full_CashFlowsUsedInObtainingControlOfSubsidiariesOrOtherBusinessesClassifiedAsInvestingActivities to ugp_PortionOfSubsequentConsiderationPaidConsistingOfCashAndCashEquivalents" order="2" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CashAndCashEquivalentsInSubsidiaryOrBusinessesAcquiredOrDisposed2013" xlink:label="ifrs-full_CashAndCashEquivalentsInSubsidiaryOrBusinessesAcquiredOrDisposed2013" xlink:title="ifrs-full_CashAndCashEquivalentsInSubsidiaryOrBusinessesAcquiredOrDisposed2013" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashFlowsUsedInObtainingControlOfSubsidiariesOrOtherBusinessesClassifiedAsInvestingActivities" xlink:to="ifrs-full_CashAndCashEquivalentsInSubsidiaryOrBusinessesAcquiredOrDisposed2013" xlink:title="Calculation : ifrs-full_CashFlowsUsedInObtainingControlOfSubsidiariesOrOtherBusinessesClassifiedAsInvestingActivities to ifrs-full_CashAndCashEquivalentsInSubsidiaryOrBusinessesAcquiredOrDisposed2013" order="3" weight="-1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/IncomeAndSocialContributionTaxesSummaryOfReconciliationOfTaxesDetail">
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_IncomeTaxExpenseContinuingOperations" xlink:label="ifrs-full_IncomeTaxExpenseContinuingOperations" xlink:title="ifrs-full_IncomeTaxExpenseContinuingOperations" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_IncomeAndSocialContributionTaxesBeforeTaxIncentives" xlink:label="ugp_IncomeAndSocialContributionTaxesBeforeTaxIncentives" xlink:title="ugp_IncomeAndSocialContributionTaxesBeforeTaxIncentives" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_IncomeTaxExpenseContinuingOperations" xlink:to="ugp_IncomeAndSocialContributionTaxesBeforeTaxIncentives" xlink:title="Calculation : ifrs-full_IncomeTaxExpenseContinuingOperations to ugp_IncomeAndSocialContributionTaxesBeforeTaxIncentives" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_TaxExpenseIncomeAtApplicableTaxRate" xlink:label="ifrs-full_TaxExpenseIncomeAtApplicableTaxRate" xlink:title="ifrs-full_TaxExpenseIncomeAtApplicableTaxRate" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_IncomeAndSocialContributionTaxesBeforeTaxIncentives" xlink:to="ifrs-full_TaxExpenseIncomeAtApplicableTaxRate" xlink:title="Calculation : ugp_IncomeAndSocialContributionTaxesBeforeTaxIncentives to ifrs-full_TaxExpenseIncomeAtApplicableTaxRate" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_TaxEffectOfExpenseNotDeductibleInDeterminingTaxableProfitTaxLoss" xlink:label="ifrs-full_TaxEffectOfExpenseNotDeductibleInDeterminingTaxableProfitTaxLoss" xlink:title="ifrs-full_TaxEffectOfExpenseNotDeductibleInDeterminingTaxableProfitTaxLoss" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_IncomeAndSocialContributionTaxesBeforeTaxIncentives" xlink:to="ifrs-full_TaxEffectOfExpenseNotDeductibleInDeterminingTaxableProfitTaxLoss" xlink:title="Calculation : ugp_IncomeAndSocialContributionTaxesBeforeTaxIncentives to ifrs-full_TaxEffectOfExpenseNotDeductibleInDeterminingTaxableProfitTaxLoss" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_TaxEffectOfRevenuesExemptFromTaxation2011" xlink:label="ifrs-full_TaxEffectOfRevenuesExemptFromTaxation2011" xlink:title="ifrs-full_TaxEffectOfRevenuesExemptFromTaxation2011" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_IncomeAndSocialContributionTaxesBeforeTaxIncentives" xlink:to="ifrs-full_TaxEffectOfRevenuesExemptFromTaxation2011" xlink:title="Calculation : ugp_IncomeAndSocialContributionTaxesBeforeTaxIncentives to ifrs-full_TaxEffectOfRevenuesExemptFromTaxation2011" order="2" weight="-1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_TaxEffectOfAdjustmentToEstimatedIncome" xlink:label="ugp_TaxEffectOfAdjustmentToEstimatedIncome" xlink:title="ugp_TaxEffectOfAdjustmentToEstimatedIncome" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_IncomeAndSocialContributionTaxesBeforeTaxIncentives" xlink:to="ugp_TaxEffectOfAdjustmentToEstimatedIncome" xlink:title="Calculation : ugp_IncomeAndSocialContributionTaxesBeforeTaxIncentives to ugp_TaxEffectOfAdjustmentToEstimatedIncome" order="3" weight="-1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_TaxEffectOfUnrecordedDeferredIncomeAndSocialContributionTaxesCarryforwardsDeferred" xlink:label="ugp_TaxEffectOfUnrecordedDeferredIncomeAndSocialContributionTaxesCarryforwardsDeferred" xlink:title="ugp_TaxEffectOfUnrecordedDeferredIncomeAndSocialContributionTaxesCarryforwardsDeferred" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_IncomeAndSocialContributionTaxesBeforeTaxIncentives" xlink:to="ugp_TaxEffectOfUnrecordedDeferredIncomeAndSocialContributionTaxesCarryforwardsDeferred" xlink:title="Calculation : ugp_IncomeAndSocialContributionTaxesBeforeTaxIncentives to ugp_TaxEffectOfUnrecordedDeferredIncomeAndSocialContributionTaxesCarryforwardsDeferred" order="4" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_TaxEffectFromInterestOnCapital" xlink:label="ugp_TaxEffectFromInterestOnCapital" xlink:title="ugp_TaxEffectFromInterestOnCapital" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_IncomeAndSocialContributionTaxesBeforeTaxIncentives" xlink:to="ugp_TaxEffectFromInterestOnCapital" xlink:title="Calculation : ugp_IncomeAndSocialContributionTaxesBeforeTaxIncentives to ugp_TaxEffectFromInterestOnCapital" order="5" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_OtherTaxEffectsForReconciliationBetweenAccountingProfitAndTaxExpenseIncome" xlink:label="ifrs-full_OtherTaxEffectsForReconciliationBetweenAccountingProfitAndTaxExpenseIncome" xlink:title="ifrs-full_OtherTaxEffectsForReconciliationBetweenAccountingProfitAndTaxExpenseIncome" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_IncomeAndSocialContributionTaxesBeforeTaxIncentives" xlink:to="ifrs-full_OtherTaxEffectsForReconciliationBetweenAccountingProfitAndTaxExpenseIncome" xlink:title="Calculation : ugp_IncomeAndSocialContributionTaxesBeforeTaxIncentives to ifrs-full_OtherTaxEffectsForReconciliationBetweenAccountingProfitAndTaxExpenseIncome" order="6" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_TaxEffectOfShareOfProfitLossOfSubsidiariesJointVenturesAndAssociates" xlink:label="ugp_TaxEffectOfShareOfProfitLossOfSubsidiariesJointVenturesAndAssociates" xlink:title="ugp_TaxEffectOfShareOfProfitLossOfSubsidiariesJointVenturesAndAssociates" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_IncomeAndSocialContributionTaxesBeforeTaxIncentives" xlink:to="ugp_TaxEffectOfShareOfProfitLossOfSubsidiariesJointVenturesAndAssociates" xlink:title="Calculation : ugp_IncomeAndSocialContributionTaxesBeforeTaxIncentives to ugp_TaxEffectOfShareOfProfitLossOfSubsidiariesJointVenturesAndAssociates" order="7" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_TaxEffectOfMonetaryVariationFromSpecialSystemForSettlementAndCustodyOnRepetitionOfTaxUnduePayments" xlink:label="ugp_TaxEffectOfMonetaryVariationFromSpecialSystemForSettlementAndCustodyOnRepetitionOfTaxUnduePayments" xlink:title="ugp_TaxEffectOfMonetaryVariationFromSpecialSystemForSettlementAndCustodyOnRepetitionOfTaxUnduePayments" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_IncomeAndSocialContributionTaxesBeforeTaxIncentives" xlink:to="ugp_TaxEffectOfMonetaryVariationFromSpecialSystemForSettlementAndCustodyOnRepetitionOfTaxUnduePayments" xlink:title="Calculation : ugp_IncomeAndSocialContributionTaxesBeforeTaxIncentives to ugp_TaxEffectOfMonetaryVariationFromSpecialSystemForSettlementAndCustodyOnRepetitionOfTaxUnduePayments" order="8" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_TaxEffectOfTaxIncentives" xlink:label="ugp_TaxEffectOfTaxIncentives" xlink:title="ugp_TaxEffectOfTaxIncentives" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_IncomeTaxExpenseContinuingOperations" xlink:to="ugp_TaxEffectOfTaxIncentives" xlink:title="Calculation : ifrs-full_IncomeTaxExpenseContinuingOperations to ugp_TaxEffectOfTaxIncentives" order="1" weight="-1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/ConsolidatedstatementsofcashflowsindirectmethodCalc2">
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_IncreaseDecreaseInCashAndCashEquivalentsFromDiscontinuedOperations" xlink:label="ugp_IncreaseDecreaseInCashAndCashEquivalentsFromDiscontinuedOperations" xlink:title="ugp_IncreaseDecreaseInCashAndCashEquivalentsFromDiscontinuedOperations" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CashFlowsFromUsedInOperatingActivitiesDiscontinuedOperations" xlink:label="ifrs-full_CashFlowsFromUsedInOperatingActivitiesDiscontinuedOperations" xlink:title="ifrs-full_CashFlowsFromUsedInOperatingActivitiesDiscontinuedOperations" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_IncreaseDecreaseInCashAndCashEquivalentsFromDiscontinuedOperations" xlink:to="ifrs-full_CashFlowsFromUsedInOperatingActivitiesDiscontinuedOperations" xlink:title="Calculation : ugp_IncreaseDecreaseInCashAndCashEquivalentsFromDiscontinuedOperations to ifrs-full_CashFlowsFromUsedInOperatingActivitiesDiscontinuedOperations" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CashFlowsFromUsedInInvestingActivitiesDiscontinuedOperations" xlink:label="ifrs-full_CashFlowsFromUsedInInvestingActivitiesDiscontinuedOperations" xlink:title="ifrs-full_CashFlowsFromUsedInInvestingActivitiesDiscontinuedOperations" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_IncreaseDecreaseInCashAndCashEquivalentsFromDiscontinuedOperations" xlink:to="ifrs-full_CashFlowsFromUsedInInvestingActivitiesDiscontinuedOperations" xlink:title="Calculation : ugp_IncreaseDecreaseInCashAndCashEquivalentsFromDiscontinuedOperations to ifrs-full_CashFlowsFromUsedInInvestingActivitiesDiscontinuedOperations" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CashFlowsFromUsedInFinancingActivitiesDiscontinuedOperations" xlink:label="ifrs-full_CashFlowsFromUsedInFinancingActivitiesDiscontinuedOperations" xlink:title="ifrs-full_CashFlowsFromUsedInFinancingActivitiesDiscontinuedOperations" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_IncreaseDecreaseInCashAndCashEquivalentsFromDiscontinuedOperations" xlink:to="ifrs-full_CashFlowsFromUsedInFinancingActivitiesDiscontinuedOperations" xlink:title="Calculation : ugp_IncreaseDecreaseInCashAndCashEquivalentsFromDiscontinuedOperations to ifrs-full_CashFlowsFromUsedInFinancingActivitiesDiscontinuedOperations" order="2" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_EffectOfExchangeRateChangesOnCashAndCashEquivalentsDiscontinuedOperations" xlink:label="ugp_EffectOfExchangeRateChangesOnCashAndCashEquivalentsDiscontinuedOperations" xlink:title="ugp_EffectOfExchangeRateChangesOnCashAndCashEquivalentsDiscontinuedOperations" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_IncreaseDecreaseInCashAndCashEquivalentsFromDiscontinuedOperations" xlink:to="ugp_EffectOfExchangeRateChangesOnCashAndCashEquivalentsDiscontinuedOperations" xlink:title="Calculation : ugp_IncreaseDecreaseInCashAndCashEquivalentsFromDiscontinuedOperations to ugp_EffectOfExchangeRateChangesOnCashAndCashEquivalentsDiscontinuedOperations" order="3" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_IncreaseDecreaseInCashAndCashEquivalentsContinuingOperations" xlink:label="ugp_IncreaseDecreaseInCashAndCashEquivalentsContinuingOperations" xlink:title="ugp_IncreaseDecreaseInCashAndCashEquivalentsContinuingOperations" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations" xlink:label="ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations" xlink:title="ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_IncreaseDecreaseInCashAndCashEquivalentsContinuingOperations" xlink:to="ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations" xlink:title="Calculation : ugp_IncreaseDecreaseInCashAndCashEquivalentsContinuingOperations to ifrs-full_CashFlowsFromUsedInOperatingActivitiesContinuingOperations" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CashFlowsFromUsedInInvestingActivitiesContinuingOperations" xlink:label="ifrs-full_CashFlowsFromUsedInInvestingActivitiesContinuingOperations" xlink:title="ifrs-full_CashFlowsFromUsedInInvestingActivitiesContinuingOperations" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_IncreaseDecreaseInCashAndCashEquivalentsContinuingOperations" xlink:to="ifrs-full_CashFlowsFromUsedInInvestingActivitiesContinuingOperations" xlink:title="Calculation : ugp_IncreaseDecreaseInCashAndCashEquivalentsContinuingOperations to ifrs-full_CashFlowsFromUsedInInvestingActivitiesContinuingOperations" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CashFlowsFromUsedInFinancingActivitiesContinuingOperations" xlink:label="ifrs-full_CashFlowsFromUsedInFinancingActivitiesContinuingOperations" xlink:title="ifrs-full_CashFlowsFromUsedInFinancingActivitiesContinuingOperations" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_IncreaseDecreaseInCashAndCashEquivalentsContinuingOperations" xlink:to="ifrs-full_CashFlowsFromUsedInFinancingActivitiesContinuingOperations" xlink:title="Calculation : ugp_IncreaseDecreaseInCashAndCashEquivalentsContinuingOperations to ifrs-full_CashFlowsFromUsedInFinancingActivitiesContinuingOperations" order="2" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_EffectOfExchangeRateChangesOnCashAndCashEquivalentsContinuingOperations" xlink:label="ugp_EffectOfExchangeRateChangesOnCashAndCashEquivalentsContinuingOperations" xlink:title="ugp_EffectOfExchangeRateChangesOnCashAndCashEquivalentsContinuingOperations" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_IncreaseDecreaseInCashAndCashEquivalentsContinuingOperations" xlink:to="ugp_EffectOfExchangeRateChangesOnCashAndCashEquivalentsContinuingOperations" xlink:title="Calculation : ugp_IncreaseDecreaseInCashAndCashEquivalentsContinuingOperations to ugp_EffectOfExchangeRateChangesOnCashAndCashEquivalentsContinuingOperations" order="3" weight="1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/DiscontinuedoperationsDetails">
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_IncreaseDecreaseInCashAndCashEquivalentsIncludingEffectOfExchangeRateChangesOnCashAndCashEquivalentsDiscontinuedOperations" xlink:label="ugp_IncreaseDecreaseInCashAndCashEquivalentsIncludingEffectOfExchangeRateChangesOnCashAndCashEquivalentsDiscontinuedOperations" xlink:title="ugp_IncreaseDecreaseInCashAndCashEquivalentsIncludingEffectOfExchangeRateChangesOnCashAndCashEquivalentsDiscontinuedOperations" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CashFlowsFromUsedInOperatingActivitiesDiscontinuedOperations" xlink:label="ifrs-full_CashFlowsFromUsedInOperatingActivitiesDiscontinuedOperations" xlink:title="ifrs-full_CashFlowsFromUsedInOperatingActivitiesDiscontinuedOperations" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_IncreaseDecreaseInCashAndCashEquivalentsIncludingEffectOfExchangeRateChangesOnCashAndCashEquivalentsDiscontinuedOperations" xlink:to="ifrs-full_CashFlowsFromUsedInOperatingActivitiesDiscontinuedOperations" xlink:title="Calculation : ugp_IncreaseDecreaseInCashAndCashEquivalentsIncludingEffectOfExchangeRateChangesOnCashAndCashEquivalentsDiscontinuedOperations to ifrs-full_CashFlowsFromUsedInOperatingActivitiesDiscontinuedOperations" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CashFlowsFromUsedInInvestingActivitiesDiscontinuedOperations" xlink:label="ifrs-full_CashFlowsFromUsedInInvestingActivitiesDiscontinuedOperations" xlink:title="ifrs-full_CashFlowsFromUsedInInvestingActivitiesDiscontinuedOperations" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_IncreaseDecreaseInCashAndCashEquivalentsIncludingEffectOfExchangeRateChangesOnCashAndCashEquivalentsDiscontinuedOperations" xlink:to="ifrs-full_CashFlowsFromUsedInInvestingActivitiesDiscontinuedOperations" xlink:title="Calculation : ugp_IncreaseDecreaseInCashAndCashEquivalentsIncludingEffectOfExchangeRateChangesOnCashAndCashEquivalentsDiscontinuedOperations to ifrs-full_CashFlowsFromUsedInInvestingActivitiesDiscontinuedOperations" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CashFlowsFromUsedInFinancingActivitiesDiscontinuedOperations" xlink:label="ifrs-full_CashFlowsFromUsedInFinancingActivitiesDiscontinuedOperations" xlink:title="ifrs-full_CashFlowsFromUsedInFinancingActivitiesDiscontinuedOperations" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_IncreaseDecreaseInCashAndCashEquivalentsIncludingEffectOfExchangeRateChangesOnCashAndCashEquivalentsDiscontinuedOperations" xlink:to="ifrs-full_CashFlowsFromUsedInFinancingActivitiesDiscontinuedOperations" xlink:title="Calculation : ugp_IncreaseDecreaseInCashAndCashEquivalentsIncludingEffectOfExchangeRateChangesOnCashAndCashEquivalentsDiscontinuedOperations to ifrs-full_CashFlowsFromUsedInFinancingActivitiesDiscontinuedOperations" order="2" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_EffectOfExchangeRateChangesOnCashAndCashEquivalentsDiscontinuedOperations" xlink:label="ugp_EffectOfExchangeRateChangesOnCashAndCashEquivalentsDiscontinuedOperations" xlink:title="ugp_EffectOfExchangeRateChangesOnCashAndCashEquivalentsDiscontinuedOperations" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_IncreaseDecreaseInCashAndCashEquivalentsIncludingEffectOfExchangeRateChangesOnCashAndCashEquivalentsDiscontinuedOperations" xlink:to="ugp_EffectOfExchangeRateChangesOnCashAndCashEquivalentsDiscontinuedOperations" xlink:title="Calculation : ugp_IncreaseDecreaseInCashAndCashEquivalentsIncludingEffectOfExchangeRateChangesOnCashAndCashEquivalentsDiscontinuedOperations to ugp_EffectOfExchangeRateChangesOnCashAndCashEquivalentsDiscontinuedOperations" order="3" weight="1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/FinancialInstrumentsSensitivityanalysiswithdevaluationoftheRealandinterestrateincreaseDetail">
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_IncomeStatementEffectDecreaseShareHoldersEquityIncreaseNetEffect" xlink:label="ugp_IncomeStatementEffectDecreaseShareHoldersEquityIncreaseNetEffect" xlink:title="ugp_IncomeStatementEffectDecreaseShareHoldersEquityIncreaseNetEffect" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_IncomeStatementEffectDecrease" xlink:label="ugp_IncomeStatementEffectDecrease" xlink:title="ugp_IncomeStatementEffectDecrease" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_IncomeStatementEffectDecreaseShareHoldersEquityIncreaseNetEffect" xlink:to="ugp_IncomeStatementEffectDecrease" xlink:title="Calculation : ugp_IncomeStatementEffectDecreaseShareHoldersEquityIncreaseNetEffect to ugp_IncomeStatementEffectDecrease" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_ExchangeRateDevaluationNetEffectOnLiabilityPosition" xlink:label="ugp_ExchangeRateDevaluationNetEffectOnLiabilityPosition" xlink:title="ugp_ExchangeRateDevaluationNetEffectOnLiabilityPosition" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_IncomeStatementEffectDecreaseShareHoldersEquityIncreaseNetEffect" xlink:to="ugp_ExchangeRateDevaluationNetEffectOnLiabilityPosition" xlink:title="Calculation : ugp_IncomeStatementEffectDecreaseShareHoldersEquityIncreaseNetEffect to ugp_ExchangeRateDevaluationNetEffectOnLiabilityPosition" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_IncomeStatementEffectincreaseShareholdersEquityDecreaseNetEffect" xlink:label="ugp_IncomeStatementEffectincreaseShareholdersEquityDecreaseNetEffect" xlink:title="ugp_IncomeStatementEffectincreaseShareholdersEquityDecreaseNetEffect" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_IncomeStatementEffectIncrease" xlink:label="ugp_IncomeStatementEffectIncrease" xlink:title="ugp_IncomeStatementEffectIncrease" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_IncomeStatementEffectincreaseShareholdersEquityDecreaseNetEffect" xlink:to="ugp_IncomeStatementEffectIncrease" xlink:title="Calculation : ugp_IncomeStatementEffectincreaseShareholdersEquityDecreaseNetEffect to ugp_IncomeStatementEffectIncrease" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_ExchangeRateAppreciationNetEffectOnLiabilityPosition" xlink:label="ugp_ExchangeRateAppreciationNetEffectOnLiabilityPosition" xlink:title="ugp_ExchangeRateAppreciationNetEffectOnLiabilityPosition" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_IncomeStatementEffectincreaseShareholdersEquityDecreaseNetEffect" xlink:to="ugp_ExchangeRateAppreciationNetEffectOnLiabilityPosition" xlink:title="Calculation : ugp_IncomeStatementEffectincreaseShareholdersEquityDecreaseNetEffect to ugp_ExchangeRateAppreciationNetEffectOnLiabilityPosition" order="1" weight="1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/EarningspershareBasicandDilutedEarningsperShareDetail">
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_AdjustedWeightedAverageShares" xlink:label="ifrs-full_AdjustedWeightedAverageShares" xlink:title="ifrs-full_AdjustedWeightedAverageShares" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_WeightedAverageShares" xlink:label="ifrs-full_WeightedAverageShares" xlink:title="ifrs-full_WeightedAverageShares" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_AdjustedWeightedAverageShares" xlink:to="ifrs-full_WeightedAverageShares" xlink:title="Calculation : ifrs-full_AdjustedWeightedAverageShares to ifrs-full_WeightedAverageShares" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_DilutiveEffectOfConvertibleInstrumentsOnNumberOfOrdinaryShares" xlink:label="ifrs-full_DilutiveEffectOfConvertibleInstrumentsOnNumberOfOrdinaryShares" xlink:title="ifrs-full_DilutiveEffectOfConvertibleInstrumentsOnNumberOfOrdinaryShares" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_AdjustedWeightedAverageShares" xlink:to="ifrs-full_DilutiveEffectOfConvertibleInstrumentsOnNumberOfOrdinaryShares" xlink:title="Calculation : ifrs-full_AdjustedWeightedAverageShares to ifrs-full_DilutiveEffectOfConvertibleInstrumentsOnNumberOfOrdinaryShares" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_DilutiveEffectOfShareOptionsOnNumberOfOrdinaryShares" xlink:label="ifrs-full_DilutiveEffectOfShareOptionsOnNumberOfOrdinaryShares" xlink:title="ifrs-full_DilutiveEffectOfShareOptionsOnNumberOfOrdinaryShares" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_AdjustedWeightedAverageShares" xlink:to="ifrs-full_DilutiveEffectOfShareOptionsOnNumberOfOrdinaryShares" xlink:title="Calculation : ifrs-full_AdjustedWeightedAverageShares to ifrs-full_DilutiveEffectOfShareOptionsOnNumberOfOrdinaryShares" order="2" weight="1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/CostsandexpensesbynatureCostsandexpensesbynatureDetailCalc2">
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ExpenseByNature" xlink:label="ifrs-full_ExpenseByNature" xlink:title="ifrs-full_ExpenseByNature" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CostOfSales" xlink:label="ifrs-full_CostOfSales" xlink:title="ifrs-full_CostOfSales" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ExpenseByNature" xlink:to="ifrs-full_CostOfSales" xlink:title="Calculation : ifrs-full_ExpenseByNature to ifrs-full_CostOfSales" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_SalesAndMarketingExpense" xlink:label="ifrs-full_SalesAndMarketingExpense" xlink:title="ifrs-full_SalesAndMarketingExpense" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ExpenseByNature" xlink:to="ifrs-full_SalesAndMarketingExpense" xlink:title="Calculation : ifrs-full_ExpenseByNature to ifrs-full_SalesAndMarketingExpense" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_GeneralAndAdministrativeExpense" xlink:label="ifrs-full_GeneralAndAdministrativeExpense" xlink:title="ifrs-full_GeneralAndAdministrativeExpense" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ExpenseByNature" xlink:to="ifrs-full_GeneralAndAdministrativeExpense" xlink:title="Calculation : ifrs-full_ExpenseByNature to ifrs-full_GeneralAndAdministrativeExpense" order="2" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_OtherOperatingIncomeExpense" xlink:label="ifrs-full_OtherOperatingIncomeExpense" xlink:title="ifrs-full_OtherOperatingIncomeExpense" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_ExpenseByNature" xlink:to="ifrs-full_OtherOperatingIncomeExpense" xlink:title="Calculation : ifrs-full_ExpenseByNature to ifrs-full_OtherOperatingIncomeExpense" order="3" weight="-1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/EquityDividendsandAllocationofNetIncomeDetailCalc2">
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_AllocationOfNetIncome" xlink:label="ugp_AllocationOfNetIncome" xlink:title="ugp_AllocationOfNetIncome" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_AllocationToLegalReserves" xlink:label="ugp_AllocationToLegalReserves" xlink:title="ugp_AllocationToLegalReserves" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_AllocationOfNetIncome" xlink:to="ugp_AllocationToLegalReserves" xlink:title="Calculation : ugp_AllocationOfNetIncome to ugp_AllocationToLegalReserves" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_AllocationOfNetIncomeToInvestmentsStatutoryReserve" xlink:label="ugp_AllocationOfNetIncomeToInvestmentsStatutoryReserve" xlink:title="ugp_AllocationOfNetIncomeToInvestmentsStatutoryReserve" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_AllocationOfNetIncome" xlink:to="ugp_AllocationOfNetIncomeToInvestmentsStatutoryReserve" xlink:title="Calculation : ugp_AllocationOfNetIncome to ugp_AllocationOfNetIncomeToInvestmentsStatutoryReserve" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_InterimDividends" xlink:label="ugp_InterimDividends" xlink:title="ugp_InterimDividends" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_AllocationOfNetIncome" xlink:to="ugp_InterimDividends" xlink:title="Calculation : ugp_AllocationOfNetIncome to ugp_InterimDividends" order="2" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_InterestOnCapitalPaidNetOfIncomeTax" xlink:label="ugp_InterestOnCapitalPaidNetOfIncomeTax" xlink:title="ugp_InterestOnCapitalPaidNetOfIncomeTax" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_AllocationOfNetIncome" xlink:to="ugp_InterestOnCapitalPaidNetOfIncomeTax" xlink:title="Calculation : ugp_AllocationOfNetIncome to ugp_InterestOnCapitalPaidNetOfIncomeTax" order="3" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_AdditionalMinimumMandatoryDividendsRecognised" xlink:label="ugp_AdditionalMinimumMandatoryDividendsRecognised" xlink:title="ugp_AdditionalMinimumMandatoryDividendsRecognised" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_AllocationOfNetIncome" xlink:to="ugp_AdditionalMinimumMandatoryDividendsRecognised" xlink:title="Calculation : ugp_AllocationOfNetIncome to ugp_AdditionalMinimumMandatoryDividendsRecognised" order="4" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_AdditionalDividendsToMinimumMandatoryDividendsRecognised" xlink:label="ugp_AdditionalDividendsToMinimumMandatoryDividendsRecognised" xlink:title="ugp_AdditionalDividendsToMinimumMandatoryDividendsRecognised" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_AllocationOfNetIncome" xlink:to="ugp_AdditionalDividendsToMinimumMandatoryDividendsRecognised" xlink:title="Calculation : ugp_AllocationOfNetIncome to ugp_AdditionalDividendsToMinimumMandatoryDividendsRecognised" order="5" weight="1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/LoansfinancingdebenturesandderivativefinancialinstrumentsSummaryofCompostionofloansDetail">
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_Borrowings" xlink:label="ifrs-full_Borrowings" xlink:title="ifrs-full_Borrowings" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_LoansReceived" xlink:label="ifrs-full_LoansReceived" xlink:title="ifrs-full_LoansReceived" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_Borrowings" xlink:to="ifrs-full_LoansReceived" xlink:title="Calculation : ifrs-full_Borrowings to ifrs-full_LoansReceived" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_ForeignCurrencyDenominatedLoans" xlink:label="ugp_ForeignCurrencyDenominatedLoans" xlink:title="ugp_ForeignCurrencyDenominatedLoans" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_LoansReceived" xlink:to="ugp_ForeignCurrencyDenominatedLoans" xlink:title="Calculation : ifrs-full_LoansReceived to ugp_ForeignCurrencyDenominatedLoans" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_BrazilianRealDenominatedLoans" xlink:label="ugp_BrazilianRealDenominatedLoans" xlink:title="ugp_BrazilianRealDenominatedLoans" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_LoansReceived" xlink:to="ugp_BrazilianRealDenominatedLoans" xlink:title="Calculation : ifrs-full_LoansReceived to ugp_BrazilianRealDenominatedLoans" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_DerivativeFinancialLiabilitiesHeldForHedging" xlink:label="ifrs-full_DerivativeFinancialLiabilitiesHeldForHedging" xlink:title="ifrs-full_DerivativeFinancialLiabilitiesHeldForHedging" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_Borrowings" xlink:to="ifrs-full_DerivativeFinancialLiabilitiesHeldForHedging" xlink:title="Calculation : ifrs-full_Borrowings to ifrs-full_DerivativeFinancialLiabilitiesHeldForHedging" order="1" weight="1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/IntangibleassetsTransfertopropertyplantandequipmentDetail">
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_AmortisationIntangibleAssetsOtherThanGoodwill" xlink:label="ifrs-full_AmortisationIntangibleAssetsOtherThanGoodwill" xlink:title="ifrs-full_AmortisationIntangibleAssetsOtherThanGoodwill" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_InventoriesAndCostOfProductsAndServicesSoldAmortisation" xlink:label="ugp_InventoriesAndCostOfProductsAndServicesSoldAmortisation" xlink:title="ugp_InventoriesAndCostOfProductsAndServicesSoldAmortisation" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_AmortisationIntangibleAssetsOtherThanGoodwill" xlink:to="ugp_InventoriesAndCostOfProductsAndServicesSoldAmortisation" xlink:title="Calculation : ifrs-full_AmortisationIntangibleAssetsOtherThanGoodwill to ugp_InventoriesAndCostOfProductsAndServicesSoldAmortisation" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_SellingAndMarketingAmortisation" xlink:label="ugp_SellingAndMarketingAmortisation" xlink:title="ugp_SellingAndMarketingAmortisation" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_AmortisationIntangibleAssetsOtherThanGoodwill" xlink:to="ugp_SellingAndMarketingAmortisation" xlink:title="Calculation : ifrs-full_AmortisationIntangibleAssetsOtherThanGoodwill to ugp_SellingAndMarketingAmortisation" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_GeneralAndAdministrativeAmortisation" xlink:label="ugp_GeneralAndAdministrativeAmortisation" xlink:title="ugp_GeneralAndAdministrativeAmortisation" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_AmortisationIntangibleAssetsOtherThanGoodwill" xlink:to="ugp_GeneralAndAdministrativeAmortisation" xlink:title="Calculation : ifrs-full_AmortisationIntangibleAssetsOtherThanGoodwill to ugp_GeneralAndAdministrativeAmortisation" order="2" weight="1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RelatedPartiesSummaryOfExpensesForCompensationOfItsKeyExecutivesDetail">
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_KeyManagementPersonnelCompensation" xlink:label="ifrs-full_KeyManagementPersonnelCompensation" xlink:title="ifrs-full_KeyManagementPersonnelCompensation" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_KeyManagementPersonnelCompensationShorttermEmployeeBenefits" xlink:label="ifrs-full_KeyManagementPersonnelCompensationShorttermEmployeeBenefits" xlink:title="ifrs-full_KeyManagementPersonnelCompensationShorttermEmployeeBenefits" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_KeyManagementPersonnelCompensation" xlink:to="ifrs-full_KeyManagementPersonnelCompensationShorttermEmployeeBenefits" xlink:title="Calculation : ifrs-full_KeyManagementPersonnelCompensation to ifrs-full_KeyManagementPersonnelCompensationShorttermEmployeeBenefits" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_KeyManagementPersonnelCompensationSharebasedPayment" xlink:label="ifrs-full_KeyManagementPersonnelCompensationSharebasedPayment" xlink:title="ifrs-full_KeyManagementPersonnelCompensationSharebasedPayment" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_KeyManagementPersonnelCompensation" xlink:to="ifrs-full_KeyManagementPersonnelCompensationSharebasedPayment" xlink:title="Calculation : ifrs-full_KeyManagementPersonnelCompensation to ifrs-full_KeyManagementPersonnelCompensationSharebasedPayment" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_KeyManagementPersonnelCompensationPostemploymentBenefits" xlink:label="ifrs-full_KeyManagementPersonnelCompensationPostemploymentBenefits" xlink:title="ifrs-full_KeyManagementPersonnelCompensationPostemploymentBenefits" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_KeyManagementPersonnelCompensation" xlink:to="ifrs-full_KeyManagementPersonnelCompensationPostemploymentBenefits" xlink:title="Calculation : ifrs-full_KeyManagementPersonnelCompensation to ifrs-full_KeyManagementPersonnelCompensationPostemploymentBenefits" order="2" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_KeyManagementPersonnelCompensationTerminationBenefits" xlink:label="ifrs-full_KeyManagementPersonnelCompensationTerminationBenefits" xlink:title="ifrs-full_KeyManagementPersonnelCompensationTerminationBenefits" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_KeyManagementPersonnelCompensation" xlink:to="ifrs-full_KeyManagementPersonnelCompensationTerminationBenefits" xlink:title="Calculation : ifrs-full_KeyManagementPersonnelCompensation to ifrs-full_KeyManagementPersonnelCompensationTerminationBenefits" order="3" weight="1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/CashandcashequivalentsfinancialinvestmentsderivativefinancialinstrumentsandotherfinancialassetsFinancialinvestmentsDetail">
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_FinancialInvestments" xlink:label="ugp_FinancialInvestments" xlink:title="ugp_FinancialInvestments" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_FinancialInvestmentsInLocalCurrency" xlink:label="ugp_FinancialInvestmentsInLocalCurrency" xlink:title="ugp_FinancialInvestmentsInLocalCurrency" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_FinancialInvestments" xlink:to="ugp_FinancialInvestmentsInLocalCurrency" xlink:title="Calculation : ugp_FinancialInvestments to ugp_FinancialInvestmentsInLocalCurrency" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_FinancialInvestmentsInForeignCurrency" xlink:label="ugp_FinancialInvestmentsInForeignCurrency" xlink:title="ugp_FinancialInvestmentsInForeignCurrency" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_FinancialInvestments" xlink:to="ugp_FinancialInvestmentsInForeignCurrency" xlink:title="Calculation : ugp_FinancialInvestments to ugp_FinancialInvestmentsInForeignCurrency" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_CurencyAndInterestRateHedgingInstruments" xlink:label="ugp_CurencyAndInterestRateHedgingInstruments" xlink:title="ugp_CurencyAndInterestRateHedgingInstruments" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ugp_FinancialInvestments" xlink:to="ugp_CurencyAndInterestRateHedgingInstruments" xlink:title="Calculation : ugp_FinancialInvestments to ugp_CurencyAndInterestRateHedgingInstruments" order="2" weight="1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/CashandcashequivalentsfinancialinvestmentsderivativefinancialinstrumentsandotherfinancialassetsCashandcashequivalentsDetail">
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CashAndCashEquivalents" xlink:label="ifrs-full_CashAndCashEquivalents" xlink:title="ifrs-full_CashAndCashEquivalents" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_CashAndBankDepositsInLocalCurrency" xlink:label="ugp_CashAndBankDepositsInLocalCurrency" xlink:title="ugp_CashAndBankDepositsInLocalCurrency" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashAndCashEquivalents" xlink:to="ugp_CashAndBankDepositsInLocalCurrency" xlink:title="Calculation : ifrs-full_CashAndCashEquivalents to ugp_CashAndBankDepositsInLocalCurrency" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_CashAndBankDepositsInForeignCurrency" xlink:label="ugp_CashAndBankDepositsInForeignCurrency" xlink:title="ugp_CashAndBankDepositsInForeignCurrency" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashAndCashEquivalents" xlink:to="ugp_CashAndBankDepositsInForeignCurrency" xlink:title="Calculation : ifrs-full_CashAndCashEquivalents to ugp_CashAndBankDepositsInForeignCurrency" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_FinancialInvestmentsConsideredCashEquivalentsInLocalCurrency" xlink:label="ugp_FinancialInvestmentsConsideredCashEquivalentsInLocalCurrency" xlink:title="ugp_FinancialInvestmentsConsideredCashEquivalentsInLocalCurrency" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashAndCashEquivalents" xlink:to="ugp_FinancialInvestmentsConsideredCashEquivalentsInLocalCurrency" xlink:title="Calculation : ifrs-full_CashAndCashEquivalents to ugp_FinancialInvestmentsConsideredCashEquivalentsInLocalCurrency" order="2" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_FinancialInvestmentsConsideredCashEquivalentsInForeignCurrency" xlink:label="ugp_FinancialInvestmentsConsideredCashEquivalentsInForeignCurrency" xlink:title="ugp_FinancialInvestmentsConsideredCashEquivalentsInForeignCurrency" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CashAndCashEquivalents" xlink:to="ugp_FinancialInvestmentsConsideredCashEquivalentsInForeignCurrency" xlink:title="Calculation : ifrs-full_CashAndCashEquivalents to ugp_FinancialInvestmentsConsideredCashEquivalentsInForeignCurrency" order="3" weight="1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Consolidatedstatementsoffinancialposition">
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_Assets" xlink:label="ifrs-full_Assets" xlink:title="ifrs-full_Assets" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CurrentAssets" xlink:label="ifrs-full_CurrentAssets" xlink:title="ifrs-full_CurrentAssets" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_Assets" xlink:to="ifrs-full_CurrentAssets" xlink:title="Calculation : ifrs-full_Assets to ifrs-full_CurrentAssets" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CashAndCashEquivalents" xlink:label="ifrs-full_CashAndCashEquivalents" xlink:title="ifrs-full_CashAndCashEquivalents" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CurrentAssets" xlink:to="ifrs-full_CashAndCashEquivalents" xlink:title="Calculation : ifrs-full_CurrentAssets to ifrs-full_CashAndCashEquivalents" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CurrentInvestments" xlink:label="ifrs-full_CurrentInvestments" xlink:title="ifrs-full_CurrentInvestments" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CurrentAssets" xlink:to="ifrs-full_CurrentInvestments" xlink:title="Calculation : ifrs-full_CurrentAssets to ifrs-full_CurrentInvestments" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CurrentTradeReceivables" xlink:label="ifrs-full_CurrentTradeReceivables" xlink:title="ifrs-full_CurrentTradeReceivables" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CurrentAssets" xlink:to="ifrs-full_CurrentTradeReceivables" xlink:title="Calculation : ifrs-full_CurrentAssets to ifrs-full_CurrentTradeReceivables" order="2" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_CurrentResellerFinancing" xlink:label="ugp_CurrentResellerFinancing" xlink:title="ugp_CurrentResellerFinancing" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CurrentAssets" xlink:to="ugp_CurrentResellerFinancing" xlink:title="Calculation : ifrs-full_CurrentAssets to ugp_CurrentResellerFinancing" order="3" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_CurrentReceivablesFromSaleOfInvestments" xlink:label="ugp_CurrentReceivablesFromSaleOfInvestments" xlink:title="ugp_CurrentReceivablesFromSaleOfInvestments" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CurrentAssets" xlink:to="ugp_CurrentReceivablesFromSaleOfInvestments" xlink:title="Calculation : ifrs-full_CurrentAssets to ugp_CurrentReceivablesFromSaleOfInvestments" order="4" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_Inventories" xlink:label="ifrs-full_Inventories" xlink:title="ifrs-full_Inventories" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CurrentAssets" xlink:to="ifrs-full_Inventories" xlink:title="Calculation : ifrs-full_CurrentAssets to ifrs-full_Inventories" order="5" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CurrentReceivablesFromTaxesOtherThanIncomeTax" xlink:label="ifrs-full_CurrentReceivablesFromTaxesOtherThanIncomeTax" xlink:title="ifrs-full_CurrentReceivablesFromTaxesOtherThanIncomeTax" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CurrentAssets" xlink:to="ifrs-full_CurrentReceivablesFromTaxesOtherThanIncomeTax" xlink:title="Calculation : ifrs-full_CurrentAssets to ifrs-full_CurrentReceivablesFromTaxesOtherThanIncomeTax" order="6" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CurrentTaxAssetsCurrent" xlink:label="ifrs-full_CurrentTaxAssetsCurrent" xlink:title="ifrs-full_CurrentTaxAssetsCurrent" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CurrentAssets" xlink:to="ifrs-full_CurrentTaxAssetsCurrent" xlink:title="Calculation : ifrs-full_CurrentAssets to ifrs-full_CurrentTaxAssetsCurrent" order="7" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_CurrentEnergyTradingFuturesContractsAssets" xlink:label="ugp_CurrentEnergyTradingFuturesContractsAssets" xlink:title="ugp_CurrentEnergyTradingFuturesContractsAssets" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CurrentAssets" xlink:to="ugp_CurrentEnergyTradingFuturesContractsAssets" xlink:title="Calculation : ifrs-full_CurrentAssets to ugp_CurrentEnergyTradingFuturesContractsAssets" order="8" weight="1" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_DividendsReceivableCurrent" xlink:label="ugp_DividendsReceivableCurrent" xlink:title="ugp_DividendsReceivableCurrent" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CurrentAssets" xlink:to="ugp_DividendsReceivableCurrent" xlink:title="Calculation : ifrs-full_CurrentAssets to ugp_DividendsReceivableCurrent" order="9" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_TradeAndOtherCurrentReceivables" xlink:label="ifrs-full_TradeAndOtherCurrentReceivables" xlink:title="ifrs-full_TradeAndOtherCurrentReceivables" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CurrentAssets" xlink:to="ifrs-full_TradeAndOtherCurrentReceivables" xlink:title="Calculation : ifrs-full_CurrentAssets to ifrs-full_TradeAndOtherCurrentReceivables" order="10" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CurrentPrepaidExpenses" xlink:label="ifrs-full_CurrentPrepaidExpenses" xlink:title="ifrs-full_CurrentPrepaidExpenses" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CurrentAssets" xlink:to="ifrs-full_CurrentPrepaidExpenses" xlink:title="Calculation : ifrs-full_CurrentAssets to ifrs-full_CurrentPrepaidExpenses" order="11" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CurrentContractAssets" xlink:label="ifrs-full_CurrentContractAssets" xlink:title="ifrs-full_CurrentContractAssets" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CurrentAssets" xlink:to="ifrs-full_CurrentContractAssets" xlink:title="Calculation : ifrs-full_CurrentAssets to ifrs-full_CurrentContractAssets" order="12" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_NoncurrentAssets" xlink:label="ifrs-full_NoncurrentAssets" xlink:title="ifrs-full_NoncurrentAssets" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_Assets" xlink:to="ifrs-full_NoncurrentAssets" xlink:title="Calculation : ifrs-full_Assets to ifrs-full_NoncurrentAssets" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_OtherNoncurrentFinancialAssets" xlink:label="ifrs-full_OtherNoncurrentFinancialAssets" xlink:title="ifrs-full_OtherNoncurrentFinancialAssets" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_NoncurrentAssets" xlink:to="ifrs-full_OtherNoncurrentFinancialAssets" xlink:title="Calculation : ifrs-full_NoncurrentAssets to ifrs-full_OtherNoncurrentFinancialAssets" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_NoncurrentTradeReceivables" xlink:label="ifrs-full_NoncurrentTradeReceivables" xlink:title="ifrs-full_NoncurrentTradeReceivables" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_NoncurrentAssets" xlink:to="ifrs-full_NoncurrentTradeReceivables" xlink:title="Calculation : ifrs-full_NoncurrentAssets to ifrs-full_NoncurrentTradeReceivables" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_NonCurrentResellerFinancing" xlink:label="ugp_NonCurrentResellerFinancing" xlink:title="ugp_NonCurrentResellerFinancing" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_NoncurrentAssets" xlink:to="ugp_NonCurrentResellerFinancing" xlink:title="Calculation : ifrs-full_NoncurrentAssets to ugp_NonCurrentResellerFinancing" order="2" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_TradeAndOtherReceivablesDueFromRelatedParties" xlink:label="ifrs-full_TradeAndOtherReceivablesDueFromRelatedParties" xlink:title="ifrs-full_TradeAndOtherReceivablesDueFromRelatedParties" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_NoncurrentAssets" xlink:to="ifrs-full_TradeAndOtherReceivablesDueFromRelatedParties" xlink:title="Calculation : ifrs-full_NoncurrentAssets to ifrs-full_TradeAndOtherReceivablesDueFromRelatedParties" order="3" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_DeferredTaxAssets" xlink:label="ifrs-full_DeferredTaxAssets" xlink:title="ifrs-full_DeferredTaxAssets" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_NoncurrentAssets" xlink:to="ifrs-full_DeferredTaxAssets" xlink:title="Calculation : ifrs-full_NoncurrentAssets to ifrs-full_DeferredTaxAssets" order="4" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_NoncurrentReceivablesFromTaxesOtherThanIncomeTax" xlink:label="ifrs-full_NoncurrentReceivablesFromTaxesOtherThanIncomeTax" xlink:title="ifrs-full_NoncurrentReceivablesFromTaxesOtherThanIncomeTax" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_NoncurrentAssets" xlink:to="ifrs-full_NoncurrentReceivablesFromTaxesOtherThanIncomeTax" xlink:title="Calculation : ifrs-full_NoncurrentAssets to ifrs-full_NoncurrentReceivablesFromTaxesOtherThanIncomeTax" order="5" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CurrentTaxAssetsNoncurrent" xlink:label="ifrs-full_CurrentTaxAssetsNoncurrent" xlink:title="ifrs-full_CurrentTaxAssetsNoncurrent" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_NoncurrentAssets" xlink:to="ifrs-full_CurrentTaxAssetsNoncurrent" xlink:title="Calculation : ifrs-full_NoncurrentAssets to ifrs-full_CurrentTaxAssetsNoncurrent" order="6" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_NoncurrentEnergyTradingFuturesContractsAssets" xlink:label="ugp_NoncurrentEnergyTradingFuturesContractsAssets" xlink:title="ugp_NoncurrentEnergyTradingFuturesContractsAssets" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_NoncurrentAssets" xlink:to="ugp_NoncurrentEnergyTradingFuturesContractsAssets" xlink:title="Calculation : ifrs-full_NoncurrentAssets to ugp_NoncurrentEnergyTradingFuturesContractsAssets" order="7" weight="1" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_LongtermDeposits" xlink:label="ifrs-full_LongtermDeposits" xlink:title="ifrs-full_LongtermDeposits" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_NoncurrentAssets" xlink:to="ifrs-full_LongtermDeposits" xlink:title="Calculation : ifrs-full_NoncurrentAssets to ifrs-full_LongtermDeposits" order="8" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_IndemnificationAssetBusinessCombination" xlink:label="ugp_IndemnificationAssetBusinessCombination" xlink:title="ugp_IndemnificationAssetBusinessCombination" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_NoncurrentAssets" xlink:to="ugp_IndemnificationAssetBusinessCombination" xlink:title="Calculation : ifrs-full_NoncurrentAssets to ugp_IndemnificationAssetBusinessCombination" order="9" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_OtherNoncurrentReceivablesAndAssets" xlink:label="ugp_OtherNoncurrentReceivablesAndAssets" xlink:title="ugp_OtherNoncurrentReceivablesAndAssets" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_NoncurrentAssets" xlink:to="ugp_OtherNoncurrentReceivablesAndAssets" xlink:title="Calculation : ifrs-full_NoncurrentAssets to ugp_OtherNoncurrentReceivablesAndAssets" order="10" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_NoncurrentPrepayments" xlink:label="ifrs-full_NoncurrentPrepayments" xlink:title="ifrs-full_NoncurrentPrepayments" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_NoncurrentAssets" xlink:to="ifrs-full_NoncurrentPrepayments" xlink:title="Calculation : ifrs-full_NoncurrentAssets to ifrs-full_NoncurrentPrepayments" order="11" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_NoncurrentContractAssets" xlink:label="ifrs-full_NoncurrentContractAssets" xlink:title="ifrs-full_NoncurrentContractAssets" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_NoncurrentAssets" xlink:to="ifrs-full_NoncurrentContractAssets" xlink:title="Calculation : ifrs-full_NoncurrentAssets to ifrs-full_NoncurrentContractAssets" order="12" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_InvestmentAccountedForUsingEquityMethod" xlink:label="ifrs-full_InvestmentAccountedForUsingEquityMethod" xlink:title="ifrs-full_InvestmentAccountedForUsingEquityMethod" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_NoncurrentAssets" xlink:to="ifrs-full_InvestmentAccountedForUsingEquityMethod" xlink:title="Calculation : ifrs-full_NoncurrentAssets to ifrs-full_InvestmentAccountedForUsingEquityMethod" order="13" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_RightofuseAssets" xlink:label="ifrs-full_RightofuseAssets" xlink:title="ifrs-full_RightofuseAssets" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_NoncurrentAssets" xlink:to="ifrs-full_RightofuseAssets" xlink:title="Calculation : ifrs-full_NoncurrentAssets to ifrs-full_RightofuseAssets" order="14" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_PropertyPlantAndEquipment" xlink:label="ifrs-full_PropertyPlantAndEquipment" xlink:title="ifrs-full_PropertyPlantAndEquipment" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_NoncurrentAssets" xlink:to="ifrs-full_PropertyPlantAndEquipment" xlink:title="Calculation : ifrs-full_NoncurrentAssets to ifrs-full_PropertyPlantAndEquipment" order="15" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_IntangibleAssetsAndGoodwill" xlink:label="ifrs-full_IntangibleAssetsAndGoodwill" xlink:title="ifrs-full_IntangibleAssetsAndGoodwill" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_NoncurrentAssets" xlink:to="ifrs-full_IntangibleAssetsAndGoodwill" xlink:title="Calculation : ifrs-full_NoncurrentAssets to ifrs-full_IntangibleAssetsAndGoodwill" order="16" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_EquityAndLiabilities" xlink:label="ifrs-full_EquityAndLiabilities" xlink:title="ifrs-full_EquityAndLiabilities" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CurrentLiabilities" xlink:label="ifrs-full_CurrentLiabilities" xlink:title="ifrs-full_CurrentLiabilities" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_EquityAndLiabilities" xlink:to="ifrs-full_CurrentLiabilities" xlink:title="Calculation : ifrs-full_EquityAndLiabilities to ifrs-full_CurrentLiabilities" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_LoansFinancingAndHedgingInstrumentsCurrent" xlink:label="ugp_LoansFinancingAndHedgingInstrumentsCurrent" xlink:title="ugp_LoansFinancingAndHedgingInstrumentsCurrent" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CurrentLiabilities" xlink:to="ugp_LoansFinancingAndHedgingInstrumentsCurrent" xlink:title="Calculation : ifrs-full_CurrentLiabilities to ugp_LoansFinancingAndHedgingInstrumentsCurrent" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CurrentNotesAndDebenturesIssuedAndCurrentPortionOfNoncurrentNotesAndDebenturesIssued" xlink:label="ifrs-full_CurrentNotesAndDebenturesIssuedAndCurrentPortionOfNoncurrentNotesAndDebenturesIssued" xlink:title="ifrs-full_CurrentNotesAndDebenturesIssuedAndCurrentPortionOfNoncurrentNotesAndDebenturesIssued" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CurrentLiabilities" xlink:to="ifrs-full_CurrentNotesAndDebenturesIssuedAndCurrentPortionOfNoncurrentNotesAndDebenturesIssued" xlink:title="Calculation : ifrs-full_CurrentLiabilities to ifrs-full_CurrentNotesAndDebenturesIssuedAndCurrentPortionOfNoncurrentNotesAndDebenturesIssued" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_TradeAndOtherCurrentPayablesToTradeSuppliers" xlink:label="ifrs-full_TradeAndOtherCurrentPayablesToTradeSuppliers" xlink:title="ifrs-full_TradeAndOtherCurrentPayablesToTradeSuppliers" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CurrentLiabilities" xlink:to="ifrs-full_TradeAndOtherCurrentPayablesToTradeSuppliers" xlink:title="Calculation : ifrs-full_CurrentLiabilities to ifrs-full_TradeAndOtherCurrentPayablesToTradeSuppliers" order="2" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_TradeCurrentPayablesReverseFactoring" xlink:label="ugp_TradeCurrentPayablesReverseFactoring" xlink:title="ugp_TradeCurrentPayablesReverseFactoring" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CurrentLiabilities" xlink:to="ugp_TradeCurrentPayablesReverseFactoring" xlink:title="Calculation : ifrs-full_CurrentLiabilities to ugp_TradeCurrentPayablesReverseFactoring" order="3" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ShorttermEmployeeBenefitsAccruals" xlink:label="ifrs-full_ShorttermEmployeeBenefitsAccruals" xlink:title="ifrs-full_ShorttermEmployeeBenefitsAccruals" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CurrentLiabilities" xlink:to="ifrs-full_ShorttermEmployeeBenefitsAccruals" xlink:title="Calculation : ifrs-full_CurrentLiabilities to ifrs-full_ShorttermEmployeeBenefitsAccruals" order="4" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CurrentPayablesOnSocialSecurityAndTaxesOtherThanIncomeTax" xlink:label="ifrs-full_CurrentPayablesOnSocialSecurityAndTaxesOtherThanIncomeTax" xlink:title="ifrs-full_CurrentPayablesOnSocialSecurityAndTaxesOtherThanIncomeTax" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CurrentLiabilities" xlink:to="ifrs-full_CurrentPayablesOnSocialSecurityAndTaxesOtherThanIncomeTax" xlink:title="Calculation : ifrs-full_CurrentLiabilities to ifrs-full_CurrentPayablesOnSocialSecurityAndTaxesOtherThanIncomeTax" order="5" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CurrentDividendPayables" xlink:label="ifrs-full_CurrentDividendPayables" xlink:title="ifrs-full_CurrentDividendPayables" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CurrentLiabilities" xlink:to="ifrs-full_CurrentDividendPayables" xlink:title="Calculation : ifrs-full_CurrentLiabilities to ifrs-full_CurrentDividendPayables" order="6" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CurrentTaxLiabilitiesCurrent" xlink:label="ifrs-full_CurrentTaxLiabilitiesCurrent" xlink:title="ifrs-full_CurrentTaxLiabilitiesCurrent" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CurrentLiabilities" xlink:to="ifrs-full_CurrentTaxLiabilitiesCurrent" xlink:title="Calculation : ifrs-full_CurrentLiabilities to ifrs-full_CurrentTaxLiabilitiesCurrent" order="7" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CurrentProvisionsForEmployeeBenefits" xlink:label="ifrs-full_CurrentProvisionsForEmployeeBenefits" xlink:title="ifrs-full_CurrentProvisionsForEmployeeBenefits" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CurrentLiabilities" xlink:to="ifrs-full_CurrentProvisionsForEmployeeBenefits" xlink:title="Calculation : ifrs-full_CurrentLiabilities to ifrs-full_CurrentProvisionsForEmployeeBenefits" order="8" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_ProvisionForDecarbonizationCredit" xlink:label="ugp_ProvisionForDecarbonizationCredit" xlink:title="ugp_ProvisionForDecarbonizationCredit" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CurrentLiabilities" xlink:to="ugp_ProvisionForDecarbonizationCredit" xlink:title="Calculation : ifrs-full_CurrentLiabilities to ugp_ProvisionForDecarbonizationCredit" order="9" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_ShorttermLegalProceedingsProvision" xlink:label="ifrs-full_ShorttermLegalProceedingsProvision" xlink:title="ifrs-full_ShorttermLegalProceedingsProvision" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CurrentLiabilities" xlink:to="ifrs-full_ShorttermLegalProceedingsProvision" xlink:title="Calculation : ifrs-full_CurrentLiabilities to ifrs-full_ShorttermLegalProceedingsProvision" order="10" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CurrentLeaseLiabilities" xlink:label="ifrs-full_CurrentLeaseLiabilities" xlink:title="ifrs-full_CurrentLeaseLiabilities" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CurrentLiabilities" xlink:to="ifrs-full_CurrentLeaseLiabilities" xlink:title="Calculation : ifrs-full_CurrentLiabilities to ifrs-full_CurrentLeaseLiabilities" order="11" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_CurrentFinancialLiabilitiesOfCustomers" xlink:label="ugp_CurrentFinancialLiabilitiesOfCustomers" xlink:title="ugp_CurrentFinancialLiabilitiesOfCustomers" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CurrentLiabilities" xlink:to="ugp_CurrentFinancialLiabilitiesOfCustomers" xlink:title="Calculation : ifrs-full_CurrentLiabilities to ugp_CurrentFinancialLiabilitiesOfCustomers" order="12" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_OtherCurrentPayables" xlink:label="ifrs-full_OtherCurrentPayables" xlink:title="ifrs-full_OtherCurrentPayables" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CurrentLiabilities" xlink:to="ifrs-full_OtherCurrentPayables" xlink:title="Calculation : ifrs-full_CurrentLiabilities to ifrs-full_OtherCurrentPayables" order="13" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_CurrentEnergyTradingFuturesContractsLiabilities" xlink:label="ugp_CurrentEnergyTradingFuturesContractsLiabilities" xlink:title="ugp_CurrentEnergyTradingFuturesContractsLiabilities" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_CurrentLiabilities" xlink:to="ugp_CurrentEnergyTradingFuturesContractsLiabilities" xlink:title="Calculation : ifrs-full_CurrentLiabilities to ugp_CurrentEnergyTradingFuturesContractsLiabilities" order="14" weight="1" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_NoncurrentLiabilities" xlink:label="ifrs-full_NoncurrentLiabilities" xlink:title="ifrs-full_NoncurrentLiabilities" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_EquityAndLiabilities" xlink:to="ifrs-full_NoncurrentLiabilities" xlink:title="Calculation : ifrs-full_EquityAndLiabilities to ifrs-full_NoncurrentLiabilities" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_LoansFinancingAndHedgingInstrumentsNonCurrent" xlink:label="ugp_LoansFinancingAndHedgingInstrumentsNonCurrent" xlink:title="ugp_LoansFinancingAndHedgingInstrumentsNonCurrent" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_NoncurrentLiabilities" xlink:to="ugp_LoansFinancingAndHedgingInstrumentsNonCurrent" xlink:title="Calculation : ifrs-full_NoncurrentLiabilities to ugp_LoansFinancingAndHedgingInstrumentsNonCurrent" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_NoncurrentPortionOfNoncurrentNotesAndDebenturesIssued" xlink:label="ifrs-full_NoncurrentPortionOfNoncurrentNotesAndDebenturesIssued" xlink:title="ifrs-full_NoncurrentPortionOfNoncurrentNotesAndDebenturesIssued" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_NoncurrentLiabilities" xlink:to="ifrs-full_NoncurrentPortionOfNoncurrentNotesAndDebenturesIssued" xlink:title="Calculation : ifrs-full_NoncurrentLiabilities to ifrs-full_NoncurrentPortionOfNoncurrentNotesAndDebenturesIssued" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_NoncurrentPayablesToRelatedParties" xlink:label="ifrs-full_NoncurrentPayablesToRelatedParties" xlink:title="ifrs-full_NoncurrentPayablesToRelatedParties" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_NoncurrentLiabilities" xlink:to="ifrs-full_NoncurrentPayablesToRelatedParties" xlink:title="Calculation : ifrs-full_NoncurrentLiabilities to ifrs-full_NoncurrentPayablesToRelatedParties" order="2" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_DeferredTaxLiabilities" xlink:label="ifrs-full_DeferredTaxLiabilities" xlink:title="ifrs-full_DeferredTaxLiabilities" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_NoncurrentLiabilities" xlink:to="ifrs-full_DeferredTaxLiabilities" xlink:title="Calculation : ifrs-full_NoncurrentLiabilities to ifrs-full_DeferredTaxLiabilities" order="3" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_NoncurrentProvisionsForEmployeeBenefits" xlink:label="ifrs-full_NoncurrentProvisionsForEmployeeBenefits" xlink:title="ifrs-full_NoncurrentProvisionsForEmployeeBenefits" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_NoncurrentLiabilities" xlink:to="ifrs-full_NoncurrentProvisionsForEmployeeBenefits" xlink:title="Calculation : ifrs-full_NoncurrentLiabilities to ifrs-full_NoncurrentProvisionsForEmployeeBenefits" order="4" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_LongtermLegalProceedingsProvision" xlink:label="ifrs-full_LongtermLegalProceedingsProvision" xlink:title="ifrs-full_LongtermLegalProceedingsProvision" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_NoncurrentLiabilities" xlink:to="ifrs-full_LongtermLegalProceedingsProvision" xlink:title="Calculation : ifrs-full_NoncurrentLiabilities to ifrs-full_LongtermLegalProceedingsProvision" order="5" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_NoncurrentLeaseLiabilities" xlink:label="ifrs-full_NoncurrentLeaseLiabilities" xlink:title="ifrs-full_NoncurrentLeaseLiabilities" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_NoncurrentLiabilities" xlink:to="ifrs-full_NoncurrentLeaseLiabilities" xlink:title="Calculation : ifrs-full_NoncurrentLiabilities to ifrs-full_NoncurrentLeaseLiabilities" order="6" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_NonCurrentFinancialLiabilitiesOfCustomers" xlink:label="ugp_NonCurrentFinancialLiabilitiesOfCustomers" xlink:title="ugp_NonCurrentFinancialLiabilitiesOfCustomers" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_NoncurrentLiabilities" xlink:to="ugp_NonCurrentFinancialLiabilitiesOfCustomers" xlink:title="Calculation : ifrs-full_NoncurrentLiabilities to ugp_NonCurrentFinancialLiabilitiesOfCustomers" order="7" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_NonCurrentIndemnificationForSubscriptionWarrants" xlink:label="ugp_NonCurrentIndemnificationForSubscriptionWarrants" xlink:title="ugp_NonCurrentIndemnificationForSubscriptionWarrants" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_NoncurrentLiabilities" xlink:to="ugp_NonCurrentIndemnificationForSubscriptionWarrants" xlink:title="Calculation : ifrs-full_NoncurrentLiabilities to ugp_NonCurrentIndemnificationForSubscriptionWarrants" order="8" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_NonCurrentProvisionForUnsecuredLiabilitiesOfSubsidiariesJointVenturesAndAssociates" xlink:label="ugp_NonCurrentProvisionForUnsecuredLiabilitiesOfSubsidiariesJointVenturesAndAssociates" xlink:title="ugp_NonCurrentProvisionForUnsecuredLiabilitiesOfSubsidiariesJointVenturesAndAssociates" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_NoncurrentLiabilities" xlink:to="ugp_NonCurrentProvisionForUnsecuredLiabilitiesOfSubsidiariesJointVenturesAndAssociates" xlink:title="Calculation : ifrs-full_NoncurrentLiabilities to ugp_NonCurrentProvisionForUnsecuredLiabilitiesOfSubsidiariesJointVenturesAndAssociates" order="9" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_OtherNoncurrentPayables" xlink:label="ifrs-full_OtherNoncurrentPayables" xlink:title="ifrs-full_OtherNoncurrentPayables" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_NoncurrentLiabilities" xlink:to="ifrs-full_OtherNoncurrentPayables" xlink:title="Calculation : ifrs-full_NoncurrentLiabilities to ifrs-full_OtherNoncurrentPayables" order="10" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_NoncurrentEnergyTradingFuturesContractsLiabilities" xlink:label="ugp_NoncurrentEnergyTradingFuturesContractsLiabilities" xlink:title="ugp_NoncurrentEnergyTradingFuturesContractsLiabilities" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_NoncurrentLiabilities" xlink:to="ugp_NoncurrentEnergyTradingFuturesContractsLiabilities" xlink:title="Calculation : ifrs-full_NoncurrentLiabilities to ugp_NoncurrentEnergyTradingFuturesContractsLiabilities" order="11" weight="1" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_Equity" xlink:label="ifrs-full_Equity" xlink:title="ifrs-full_Equity" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_EquityAndLiabilities" xlink:to="ifrs-full_Equity" xlink:title="Calculation : ifrs-full_EquityAndLiabilities to ifrs-full_Equity" order="2" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_EquityAttributableToOwnersOfParent" xlink:label="ifrs-full_EquityAttributableToOwnersOfParent" xlink:title="ifrs-full_EquityAttributableToOwnersOfParent" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_Equity" xlink:to="ifrs-full_EquityAttributableToOwnersOfParent" xlink:title="Calculation : ifrs-full_Equity to ifrs-full_EquityAttributableToOwnersOfParent" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_IssuedCapital" xlink:label="ifrs-full_IssuedCapital" xlink:title="ifrs-full_IssuedCapital" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_EquityAttributableToOwnersOfParent" xlink:to="ifrs-full_IssuedCapital" xlink:title="Calculation : ifrs-full_EquityAttributableToOwnersOfParent to ifrs-full_IssuedCapital" order="0" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_EquityInstrumentsGranted" xlink:label="ugp_EquityInstrumentsGranted" xlink:title="ugp_EquityInstrumentsGranted" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_EquityAttributableToOwnersOfParent" xlink:to="ugp_EquityInstrumentsGranted" xlink:title="Calculation : ifrs-full_EquityAttributableToOwnersOfParent to ugp_EquityInstrumentsGranted" order="1" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_CapitalReserve" xlink:label="ifrs-full_CapitalReserve" xlink:title="ifrs-full_CapitalReserve" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_EquityAttributableToOwnersOfParent" xlink:to="ifrs-full_CapitalReserve" xlink:title="Calculation : ifrs-full_EquityAttributableToOwnersOfParent to ifrs-full_CapitalReserve" order="2" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_TreasuryShares" xlink:label="ifrs-full_TreasuryShares" xlink:title="ifrs-full_TreasuryShares" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_EquityAttributableToOwnersOfParent" xlink:to="ifrs-full_TreasuryShares" xlink:title="Calculation : ifrs-full_EquityAttributableToOwnersOfParent to ifrs-full_TreasuryShares" order="3" weight="-1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_OtherReserves" xlink:label="ifrs-full_OtherReserves" xlink:title="ifrs-full_OtherReserves" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_EquityAttributableToOwnersOfParent" xlink:to="ifrs-full_OtherReserves" xlink:title="Calculation : ifrs-full_EquityAttributableToOwnersOfParent to ifrs-full_OtherReserves" order="4" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_ProfitReserves" xlink:label="ugp_ProfitReserves" xlink:title="ugp_ProfitReserves" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_EquityAttributableToOwnersOfParent" xlink:to="ugp_ProfitReserves" xlink:title="Calculation : ifrs-full_EquityAttributableToOwnersOfParent to ugp_ProfitReserves" order="5" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_AccumulatedOtherComprehensiveIncome" xlink:label="ifrs-full_AccumulatedOtherComprehensiveIncome" xlink:title="ifrs-full_AccumulatedOtherComprehensiveIncome" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_EquityAttributableToOwnersOfParent" xlink:to="ifrs-full_AccumulatedOtherComprehensiveIncome" xlink:title="Calculation : ifrs-full_EquityAttributableToOwnersOfParent to ifrs-full_AccumulatedOtherComprehensiveIncome" order="6" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="ugp-20241231.xsd#ugp_AdditionalDividendsMinimumMandatoryDividends" xlink:label="ugp_AdditionalDividendsMinimumMandatoryDividends" xlink:title="ugp_AdditionalDividendsMinimumMandatoryDividends" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_EquityAttributableToOwnersOfParent" xlink:to="ugp_AdditionalDividendsMinimumMandatoryDividends" xlink:title="Calculation : ifrs-full_EquityAttributableToOwnersOfParent to ugp_AdditionalDividendsMinimumMandatoryDividends" order="7" weight="1" use="optional" />
    <link:loc xlink:type="locator" xlink:href="https://xbrl.ifrs.org/taxonomy/2024-03-27/full_ifrs/full_ifrs-cor_2024-03-27.xsd#ifrs-full_NoncontrollingInterests" xlink:label="ifrs-full_NoncontrollingInterests" xlink:title="ifrs-full_NoncontrollingInterests" />
    <link:calculationArc xlink:type="arc" xlink:arcrole="http://www.xbrl.org/2003/arcrole/summation-item" xlink:from="ifrs-full_Equity" xlink:to="ifrs-full_NoncontrollingInterests" xlink:title="Calculation : ifrs-full_Equity to ifrs-full_NoncontrollingInterests" order="1" weight="1" use="optional" />
  </link:calculationLink>
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/CoverPage" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/ConsolidatedstatementsofchangesinequityParenthetical" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Operations" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Basisofpreparationandpresentationofconsolidatedfinancialstatements" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Newaccountingpoliciesandchangesinaccountingpolicies" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/PrinciplesOfConsolidationAndInvestmentsInSubsidiaries" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Cashandcashequivalentsfinancialinvestmentsderivativefinancialinstrumentsandotherfinancialassets" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Tradereceivablesresellerfinancingandotherreceivables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Inventories" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Recoverabletaxes" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RelatedParties" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/IncomeAndSocialContributionTaxes" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/PrepaidExpenses" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Contractualassetswithcustomersexclusivityrights" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Investmentsinsubsidiariesjointventuresandassociates" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Rightofuseassetsandleasespayable" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Propertyplantandequipment" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Intangibleassets" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Loansfinancingdebenturesandderivativefinancialinstruments" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Tradepayables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Salariesandrelatedcharges" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/TaxesPayable" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Employeebenefitsandprivatepensionplan" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Provisionforassetretirementobligation" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Provisionsandcontingentliabilities" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/DeferredRevenue" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/SubscriptionWarrantsIndemnification" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Equity" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Costsexpensesandotheroperatingresultsbynature" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Gainlossondisposalofpropertyplantandequipmentandintangibleassets" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Otheroperatingincomenet" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Financialresult" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Earningspershare" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Segmentinformation" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/FinancialInstruments" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Commitments" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/AcquisitionofInterestandControl" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Discontinuedoperations" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/Eventsafterthereportingperiod" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/BasisofpreparationandpresentationofconsolidatedfinancialstatementsPolicies" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/OperationsTables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/PresentationOfFinancialStatementsAndSummaryOfSignificantAccountingPoliciesTables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/CashandcashequivalentsfinancialinvestmentsderivativefinancialinstrumentsandotherfinancialassetsTables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/TradereceivablesresellerfinancingandotherreceivablesTables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/InventoriesTables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RecoverabletaxesTables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RelatedPartiesTables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/IncomeAndSocialContributionTaxesTables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/PrepaidExpensesTables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/ContractualassetswithcustomersexclusivityrightsTables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/InvestmentsinsubsidiariesjointventuresandassociatesTables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RightofuseassetsandleasespayableTables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/PropertyPlantAndEquipmentTables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/IntangibleassetsTables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/LoansfinancingdebenturesandderivativefinancialinstrumentsTables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/TradePayablesTables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/SalariesandrelatedchargesTables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/TaxesPayableTables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/EmployeebenefitsandprivatepensionplanTables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/ProvisionforassetretirementobligationTables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/ProvisionsandcontingentliabilitiesTables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/DeferredRevenueTables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/EquityTables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/CostsexpensesandotheroperatingresultsbynatureTables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/OtheroperatingincomenetTables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/FinancialresultTables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/EarningspershareTables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/SegmentinformationTables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/FinancialInstrumentsTables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/CommitmentsTables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/AcquisitionofInterestandControlTables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/DiscontinuedoperationsTables" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/OperationsDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/OperationsOperationalimpactsDetailsTextuals" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/OperationsMainrisksandassociatedmeasuresDetailsTextuals" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/BasisofpreparationandpresentationoftheconsolidatedfinancialstatementsandsignificantaccountingpoliciesAdditionalInformationDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/CashandcashequivalentsfinancialinvestmentsandderivativefinancialinstrumentsAdditionalInformationDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/TradereceivablesresellerfinancingandotherreceivablesSummaryofMovementsintheAllowanceforLossAllowanceforExpectedCreditLossesDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/TradereceivablesresellerfinancingandotherreceivablesSummaryofofTradeReceivablesGrossofLossAllowanceforExpectedCreditLossesDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/TradereceivablesresellerfinancingandotherreceivablessaleofsubsidiariesDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/TradeReceivablesandResellerFinancingTradereceivablesDetailCalc2" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/TradereceivablesresellerfinancingandotherreceivablesBreakdownofLossAllowanceforExpectedCreditLossesDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/TradereceivablesresellerfinancingandotherreceivablesBreakdownofResellerFinancingGrossofLossAllowanceforExpectedCreditLossesDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/TradereceivablesresellerfinancingandotherreceivablesAdditionalInformationDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/InventoriesBreakdownofInventoriesDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/InventoriesMovementsintheProvisionforinventoryLossesDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/InventoriesBreakdownofProvisionforLossesRelatedtoInventoriesDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RecoverabletaxesScheduleofestimatedrecoveryofICMScreditsDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RecoverabletaxesScheduleofestimatedrecoveryofPISandCOFINScreditsDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RecoverabletaxesAdditionalInformationDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RelatedPartiesSummaryOfSubsidiariesAndOtherRelatedPartiesDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RelatedPartiesSummarizedChangesOfNumberOfRestrictedAndPerformanceSharesGrantedDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RelatedPartiesAdditionalInformationDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/IncomeAndSocialContributionTaxesSummaryOfChangesInBalancesOfDeferredTaxesDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/IncomeAndSocialContributionTaxesSummaryOfDeferredIncomeAndSocialContributionTaxAssetsDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/IncomeAndSocialContributionTaxesAdditionalInformationDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/ContractualassetswithcustomersexclusivityrightsSummaryofContractualAssetswithCustomersExclusiveRightsBalanceandChangesDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/InvestmentsinsubsidiariesjointventuresandassociatesSummaryofthepositionsofequityandincomelossfortheyearDetails" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/InvestmentsinsubsidiariesjointventuresandassociatesSummaryoffinancialpositionandincomeofsubsidiarieswhichhaverelevantnoncontrollinginterestsDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/InvestmentsinsubsidiariesjointventuresandassociatesSummaryofstatementsoffinancialinformationofjointventuresandassociatesDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/InvestmentsinsubsidiariesjointventuresandassociatesSummaryofbalancesandchangesininvestmentsinjointventuresandassociatesDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/InvestmentsinsubsidiariesjointventuresandassociatesDetailsTextuals" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RightofuseassetsandleasespayableSummaryofInformationAboutRightofUseAssetsDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RightofuseassetsandleasespayableSummaryofInformationAboutRightofUseAssetsDetailParenthetical" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RightofuseassetsandleasespayableSummaryofChangesinLeasePayablesDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RightofuseassetsandleasespayableSummaryofMaturitiesofLeasePaymentsofOperatingLeaseDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RightofuseassetsandleasespayableSummaryofweightedaveragediscountratesfortheleasepayableDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RightofuseassetsandleasespayableDetailsaboutleasecontractsoflowamountassetsDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RightofuseassetsandleasespayableAdditionalInformationDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/PropertyPlantAndEquipmentBalancesAndChangesInPropertyPlantAndEquipmentBeginningAndEndingDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/IntangibleassetsBalanceandchangesinintangibleassetsDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/IntangibleassetsBalancesofgoodwillDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/IntangibleassetsBalancesofgoodwillParentheticalDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/IntangibleassetsAdditionalInformationDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/LoansfinancingdebenturesandderivativefinancialinstrumentsSummaryofChangesinLoansDebenturesandFinanceLeasesDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/LoansfinancingdebenturesandderivativefinancialinstrumentsSummaryofPrincipalMaturityScheduleDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/LoansfinancingdebenturesandderivativefinancialinstrumentsSummaryofTransactionCostsDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/LoansfinancingdebenturesandderivativefinancialinstrumentsSummaryofAppropriatedProfitorLossinTheFutureDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/LoansfinancingdebenturesandderivativefinancialinstrumentsSummaryofmainoperationscontractedloansDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/LoansfinancingdebenturesandderivativefinancialinstrumentsSummaryofDebenturesDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/LoansfinancingdebenturesandderivativefinancialinstrumentsNarrativeofDebenturesDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/LoansfinancingdebenturesandderivativefinancialinstrumentsSummaryofLoanMaturityDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/LoansfinancingdebenturesandderivativefinancialinstrumentsSummaryofForeignLoanMaturityDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/LoansfinancingdebenturesandderivativefinancialinstrumentsAdditionalInformationDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/TradePayablesSummaryOfTradePayablesDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/EmployeebenefitsandprivatepensionplanAdditionalinformationDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/EmployeebenefitsandprivatepensionplanChangesinprovisionforpostemploymentbenefitsDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/EmployeebenefitsandprivatepensionplanPostemploymentbenefitexpenseDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/EmployeebenefitsandprivatepensionplanSignificantactuarialassumptionsadoptedDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/EmployeebenefitsandprivatepensionplanSensitivityanalysisDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/ProvisionsandcontingentliabilitiesBalancesofescrowdepositsDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/ProvisionsandcontingentliabilitiesContingentliabilitiespossiblebynatureDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/ProvisionsandcontingentliabilitiesAdditionalinformationDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/DeferredRevenueDeferredRevenueInSubsidiariesDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/DeferredRevenueAdditionalInformationDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/SubscriptionWarrantsIndemnificationAdditionalInformationDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/EquityAdditionalInformationDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/EquityBalanceoftreasurysharesDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/EquityBalanceOfOtherComprehensiveIncomeDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/EquityDividendsAndAllocationOfNetIncomeParentheticalDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/EquitySummaryofBalancesandChangesinDividendsPayableDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/CostsandexpensesbynatureAdditionalinformationDetails" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/EarningspershareAdditionalInformationDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/SegmentInformationRevenueFromOperationsAbroadDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/SegmentInformationRightofuseAssetsPPEandIntangibleAssetsoftheCompanyAbroadDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/FinancialInstrumentsSummaryofthefinancialassetsandfinancialliabilitiesmeasuredatfairvalueDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/FinancialInstrumentsChangesinfinancialliabilitiesmeasuredatlevel3ofthefairvaluehierarchyDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/FinancialInstrumentsDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/FinancialInstrumentsPositionsofderivativefinancialinstrumentstohedgecommoditypriceriskDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/FinancialInstrumentsSummaryofcreditriskoffinancialinstitutionandgovernmentofcashcashequivalentsandfinancialinvestmentsDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/FinancialInstrumentsContractualundiscountedcashoutflowsDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/FinancialInstrumentsSummarythepositionofhedginginstrumentsDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/FinancialInstrumentsSensitivityanalysislevel2hierarchyDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/FinancialInstrumentsAdditionalInformationDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RisksAndFinancialInstrumentsFinancialAssetsAndLiabilitiesExposedToFloatingInterestRatesDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RisksandFinancialInstrumentsSensitivityanalysisoffloatinginterestrateriskDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RisksandFinancialInstrumentsLossallowanceforexpectedcreditlossesbalancesontradereceivablesDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RisksandFinancialInstrumentsCreditriskexposureDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RisksandFinancialInstrumentsSummaryoflossallowanceforexpectedcreditlossesbalancesbygeographicareaDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RisksandFinancialInstrumentsSummaryofforeignexchangehedginginstrumentsdesignatedasfairvaluehedgeDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/CommitmentsContractsDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/CommitmentsAdditionalInformationDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/CommitmentsMinimumAnnualPurchasesDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/AcquisitionofInterestandControlScheduleofacquiredintangibleassetsthatwerenotrecognizedinthebooksoftheacquiredentityDetails" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/AcquisitionofInterestandControlAdditionalInformationDetails" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/DiscontinuedoperationsDetailsTextuals" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/EventsafterthereportingperiodAdditionalInformationDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/InvestmentSummaryOfBalancesAndChangesInJointVenturesDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/InvestmentSummaryofprovisionforshorttermliabilitiesDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/InvestmentsSummaryofreconciliationofshareofprofitlossofsubsidiariesjointventuresandassociatesDetails" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/InvestmentSummaryOfBalancesAndChangesInAssociatesDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RecoverabletaxesSummaryofestimatedrecoveryofICMSassetsDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RecoverabletaxesSummaryofestimatedrecoveryofPISandCOFINScreditDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RightofuseassetsandleasespayableSummaryofAmortizationExpensesintheFinancialStatementsDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RelatedPartiesSummaryOfSubsidiariesAndOtherRelatedPartiesParentheticalDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/IncomeandSocialContributionTaxesSummaryoftaxlosscarryforwardsDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/SegmentInformationAdditionstoPropertyPlantandEquipmentandintangibleAssetsandContractualassetswithcustomersexclusiverightsDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/LoansfinancingdebenturesandderivativefinancialinstrumentsNotesDetailsTextual" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/DiscontinuedoperationsDetails3Textuals2" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/ProvisionforassetretirementobligationChangesintheprovisionforassetretirementobligationDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/LoansfinancingdebenturesandderivativefinancialinstrumentsSummaryofCollateraltoFinancialInstitutionsDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RisksAndFinancialInstrumentsContractualUndiscountedCashOutflowsParentheticalDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RisksAndFinancialInstrumentsValueOfGainsLossesRecognizedDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RisksAndFinancialInstrumentsFairValuesAndTheCarryingValuesOfTheFinancialInstrumentsDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RisksAndFinancialInstrumentsChangesInExchangeRateDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RecoverabletaxesConsolidatedSummaryofRecoverableIncomeTaxandSocialContributionTaxesDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RelatedPartiesSummaryOfSharesGrantedDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/RelatedPartiesChangesOfNumberOfSharesGrantedDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/IncomeAndSocialContributionTaxesSummaryOfTaxIncentivesDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/PrepaidExpensesSummaryOfPrepaidExpensesDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/PrepaidExpensesSummaryofPrepaidExpensesDetailCalc2" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/EquityBalanceAndChangesInCumulativeTranslationAdjustmentsDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/AcquisitionofInterestandControlScheduleofearnoutsensitivityanalysisDetails" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/AcquisitionofInterestandControlScheduleofbreakdownoftheacquisitionvalueconsideringtheworkingcapitalandnetdebtadjustmentsandprimarycontributionDetails" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/SalariesAndRelatedChargesSummaryOfSalariesAndRelatedChargesDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/TaxesPayableSummaryOfTaxesPayableDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/GainlossondisposalofpropertyplantandequipmentandintangibleassetsAdditionalinformationDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/OtheroperatingincomenetOtheroperatingincomenetDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/InvestmentsinsubsidiariesjointventuresandassociatesSummaryofAmountsofBalanceSheetsandIncomeStatementsofAssociatesDetail" />
  <link:calculationLink xlink:type="extended" xlink:role="http://www.ultrapar.com/role/PropertyPlantAndEquipmentSummaryOfDepreciationExpensesInTheFinancialStatementsDetail" />
</link:linkbase>
