diff --git a/phosphor-power-supply/meson.build b/phosphor-power-supply/meson.build
index 35034b3..9b1d423 100644
--- a/phosphor-power-supply/meson.build
+++ b/phosphor-power-supply/meson.build
@@ -10,7 +10,6 @@
     'util.cpp',
     dependencies: [
         cli11_dep,
-        fmt,
         libgpiodcxx,
         nlohmann_json_dep,
         phosphor_dbus_interfaces,
diff --git a/phosphor-power-supply/power_supply.cpp b/phosphor-power-supply/power_supply.cpp
index 6ec8115..1f65fb2 100644
--- a/phosphor-power-supply/power_supply.cpp
+++ b/phosphor-power-supply/power_supply.cpp
@@ -5,13 +5,12 @@
 #include "types.hpp"
 #include "util.hpp"
 
-#include <fmt/format.h>
-
 #include <xyz/openbmc_project/Common/Device/error.hpp>
 
 #include <chrono>  // sleep_for()
 #include <cmath>
 #include <cstdint> // uint8_t...
+#include <format>
 #include <fstream>
 #include <regex>
 #include <thread> // sleep_for()
@@ -47,7 +46,7 @@
     shortName = findShortName(inventoryPath);
 
     log<level::DEBUG>(
-        fmt::format("{} gpioLineName: {}", shortName, gpioLineName).c_str());
+        std::format("{} gpioLineName: {}", shortName, gpioLineName).c_str());
     presenceGPIO = createGPIO(gpioLineName);
 
     std::ostringstream ss;
@@ -130,14 +129,14 @@
     {
         std::this_thread::sleep_for(std::chrono::milliseconds(bindDelay));
         log<level::INFO>(
-            fmt::format("Binding device driver. path: {} device: {}",
+            std::format("Binding device driver. path: {} device: {}",
                         path.string(), bindDevice)
                 .c_str());
     }
     else
     {
         log<level::INFO>(
-            fmt::format("Unbinding device driver. path: {} device: {}",
+            std::format("Unbinding device driver. path: {} device: {}",
                         path.string(), bindDevice)
                 .c_str());
     }
@@ -158,7 +157,7 @@
         auto err = errno;
 
         log<level::ERR>(
-            fmt::format("Failed binding or unbinding device. errno={}", err)
+            std::format("Failed binding or unbinding device. errno={}", err)
                 .c_str());
     }
 }
@@ -174,7 +173,7 @@
         // Relying on property change or interface added to retry.
         // Log an informational trace to the journal.
         log<level::INFO>(
-            fmt::format("D-Bus property {} access failure exception",
+            std::format("D-Bus property {} access failure exception",
                         inventoryPath)
                 .c_str());
     }
@@ -198,13 +197,13 @@
     catch (const std::exception& e)
     {
         log<level::ERR>(
-            fmt::format("presenceGPIO read fail: {}", e.what()).c_str());
+            std::format("presenceGPIO read fail: {}", e.what()).c_str());
         throw;
     }
 
     if (presentOld != present)
     {
-        log<level::DEBUG>(fmt::format("{} presentOld: {} present: {}",
+        log<level::DEBUG>(std::format("{} presentOld: {} present: {}",
                                       shortName, presentOld, present)
                               .c_str());
 
@@ -251,7 +250,7 @@
             if (statusWord != statusWordOld)
             {
                 log<level::ERR>(
-                    fmt::format("{} CML fault: STATUS_WORD = {:#06x}, "
+                    std::format("{} CML fault: STATUS_WORD = {:#06x}, "
                                 "STATUS_CML = {:#02x}",
                                 shortName, statusWord, statusCML)
                         .c_str());
@@ -274,7 +273,7 @@
             if (statusWord != statusWordOld)
             {
                 log<level::ERR>(
-                    fmt::format("{} INPUT fault: STATUS_WORD = {:#06x}, "
+                    std::format("{} INPUT fault: STATUS_WORD = {:#06x}, "
                                 "STATUS_MFR_SPECIFIC = {:#04x}, "
                                 "STATUS_INPUT = {:#04x}",
                                 shortName, statusWord, statusMFR, statusInput)
@@ -290,7 +289,7 @@
         !(statusWord & phosphor::pmbus::status_word::INPUT_FAULT_WARN))
     {
         log<level::INFO>(
-            fmt::format("{} INPUT fault cleared: STATUS_WORD = {:#06x}, "
+            std::format("{} INPUT fault cleared: STATUS_WORD = {:#06x}, "
                         "STATUS_MFR_SPECIFIC = {:#04x}, "
                         "STATUS_INPUT = {:#04x}",
                         shortName, statusWord, statusMFR, statusInput)
@@ -308,7 +307,7 @@
             if (statusWord != statusWordOld)
             {
                 log<level::ERR>(
-                    fmt::format(
+                    std::format(
                         "{} VOUT_OV_FAULT fault: STATUS_WORD = {:#06x}, "
                         "STATUS_MFR_SPECIFIC = {:#04x}, "
                         "STATUS_VOUT = {:#02x}",
@@ -334,7 +333,7 @@
             if (statusWord != statusWordOld)
             {
                 log<level::ERR>(
-                    fmt::format("{} IOUT fault: STATUS_WORD = {:#06x}, "
+                    std::format("{} IOUT fault: STATUS_WORD = {:#06x}, "
                                 "STATUS_MFR_SPECIFIC = {:#04x}, "
                                 "STATUS_IOUT = {:#04x}",
                                 shortName, statusWord, statusMFR, statusIout)
@@ -360,7 +359,7 @@
             if (statusWord != statusWordOld)
             {
                 log<level::ERR>(
-                    fmt::format(
+                    std::format(
                         "{} VOUT_UV_FAULT fault: STATUS_WORD = {:#06x}, "
                         "STATUS_MFR_SPECIFIC = {:#04x}, "
                         "STATUS_VOUT = {:#04x}",
@@ -384,7 +383,7 @@
         {
             if (statusWord != statusWordOld)
             {
-                log<level::ERR>(fmt::format("{} FANS fault/warning: "
+                log<level::ERR>(std::format("{} FANS fault/warning: "
                                             "STATUS_WORD = {:#06x}, "
                                             "STATUS_MFR_SPECIFIC = {:#04x}, "
                                             "STATUS_FANS_1_2 = {:#04x}",
@@ -409,7 +408,7 @@
         {
             if (statusWord != statusWordOld)
             {
-                log<level::ERR>(fmt::format("{} TEMPERATURE fault/warning: "
+                log<level::ERR>(std::format("{} TEMPERATURE fault/warning: "
                                             "STATUS_WORD = {:#06x}, "
                                             "STATUS_MFR_SPECIFIC = {:#04x}, "
                                             "STATUS_TEMPERATURE = {:#04x}",
@@ -435,7 +434,7 @@
         {
             if (statusWord != statusWordOld)
             {
-                log<level::ERR>(fmt::format("{} PGOOD fault: "
+                log<level::ERR>(std::format("{} PGOOD fault: "
                                             "STATUS_WORD = {:#06x}, "
                                             "STATUS_MFR_SPECIFIC = {:#04x}",
                                             shortName, statusWord, statusMFR)
@@ -501,7 +500,7 @@
         {
             if (statusWord != statusWordOld)
             {
-                log<level::ERR>(fmt::format("{} MFR fault: "
+                log<level::ERR>(std::format("{} MFR fault: "
                                             "STATUS_WORD = {:#06x} "
                                             "STATUS_MFR_SPECIFIC = {:#04x}",
                                             shortName, statusWord, statusMFR)
@@ -527,7 +526,7 @@
             if (statusWord != statusWordOld)
             {
                 log<level::ERR>(
-                    fmt::format("{} VIN_UV fault: STATUS_WORD = {:#06x}, "
+                    std::format("{} VIN_UV fault: STATUS_WORD = {:#06x}, "
                                 "STATUS_MFR_SPECIFIC = {:#04x}, "
                                 "STATUS_INPUT = {:#04x}",
                                 shortName, statusWord, statusMFR, statusInput)
@@ -543,7 +542,7 @@
         if (vinUVFault != 0)
         {
             log<level::INFO>(
-                fmt::format("{} VIN_UV fault cleared: STATUS_WORD = {:#06x}, "
+                std::format("{} VIN_UV fault cleared: STATUS_WORD = {:#06x}, "
                             "STATUS_MFR_SPECIFIC = {:#04x}, "
                             "STATUS_INPUT = {:#04x}",
                             shortName, statusWord, statusMFR, statusInput)
@@ -617,7 +616,7 @@
             {
                 if (statusWord != statusWordOld)
                 {
-                    log<level::INFO>(fmt::format("{} STATUS_WORD = {:#06x}",
+                    log<level::INFO>(std::format("{} STATUS_WORD = {:#06x}",
                                                  shortName, statusWord)
                                          .c_str());
                 }
@@ -626,7 +625,7 @@
                 if (inputFault)
                 {
                     log<level::INFO>(
-                        fmt::format(
+                        std::format(
                             "{} INPUT fault cleared: STATUS_WORD = {:#06x}",
                             shortName, statusWord)
                             .c_str());
@@ -635,7 +634,7 @@
                 if (vinUVFault)
                 {
                     log<level::INFO>(
-                        fmt::format("{} VIN_UV cleared: STATUS_WORD = {:#06x}",
+                        std::format("{} VIN_UV cleared: STATUS_WORD = {:#06x}",
                                     shortName, statusWord)
                             .c_str());
                 }
@@ -643,7 +642,7 @@
                 if (pgoodFault > 0)
                 {
                     log<level::INFO>(
-                        fmt::format("{} pgoodFault cleared", shortName)
+                        std::format("{} pgoodFault cleared", shortName)
                             .c_str());
                 }
 
@@ -666,7 +665,7 @@
                 (inputVoltage != in_input::VIN_VOLTAGE_0))
             {
                 log<level::INFO>(
-                    fmt::format(
+                    std::format(
                         "{} READ_VIN back in range: actualInputVoltageOld = {} "
                         "actualInputVoltage = {}",
                         shortName, actualInputVoltageOld, actualInputVoltage)
@@ -676,7 +675,7 @@
             else if (vinUVFault && (inputVoltage != in_input::VIN_VOLTAGE_0))
             {
                 log<level::INFO>(
-                    fmt::format(
+                    std::format(
                         "{} CLEAR_FAULTS: vinUVFault {} actualInputVoltage {}",
                         shortName, vinUVFault, actualInputVoltage)
                         .c_str());
@@ -689,7 +688,7 @@
                      10.0)
             {
                 log<level::INFO>(
-                    fmt::format(
+                    std::format(
                         "{} actualInputVoltageOld = {} actualInputVoltage = {}",
                         shortName, actualInputVoltageOld, actualInputVoltage)
                         .c_str());
@@ -761,7 +760,7 @@
 void PowerSupply::clearFaults()
 {
     log<level::DEBUG>(
-        fmt::format("clearFaults() inventoryPath: {}", inventoryPath).c_str());
+        std::format("clearFaults() inventoryPath: {}", inventoryPath).c_str());
     faultLogged = false;
     // The PMBus device driver does not allow for writing CLEAR_FAULTS
     // directly. However, the pmbus hwmon device driver code will send a
@@ -844,7 +843,7 @@
             {
                 present = std::get<bool>(property->second);
 
-                log<level::INFO>(fmt::format("Power Supply {} Present {}",
+                log<level::INFO>(std::format("Power Supply {} Present {}",
                                              inventoryPath, present)
                                      .c_str());
 
@@ -879,7 +878,7 @@
 
     if (vpdValue.size() != vpdSize)
     {
-        log<level::INFO>(fmt::format("{} {} resize needed. size: {}", shortName,
+        log<level::INFO>(std::format("{} {} resize needed. size: {}", shortName,
                                      vpdName, vpdValue.size())
                              .c_str());
         vpdValue.resize(vpdSize, ' ');
@@ -929,7 +928,7 @@
     ObjectMap object;
 #endif
     log<level::DEBUG>(
-        fmt::format("updateInventory() inventoryPath: {}", inventoryPath)
+        std::format("updateInventory() inventoryPath: {}", inventoryPath)
             .c_str());
 
     if (present)
@@ -1054,14 +1053,14 @@
             // Read max_power_out, should be direct format
             auto maxPowerOutStr = pmbusIntf->readString(MFR_POUT_MAX,
                                                         Type::HwmonDeviceDebug);
-            log<level::INFO>(fmt::format("{} MFR_POUT_MAX read {}", shortName,
+            log<level::INFO>(std::format("{} MFR_POUT_MAX read {}", shortName,
                                          maxPowerOutStr)
                                  .c_str());
             maxPowerOut = std::stod(maxPowerOutStr);
         }
         catch (const std::exception& e)
         {
-            log<level::ERR>(fmt::format("{} MFR_POUT_MAX read error: {}",
+            log<level::ERR>(std::format("{} MFR_POUT_MAX read error: {}",
                                         shortName, e.what())
                                 .c_str());
         }
@@ -1090,7 +1089,7 @@
     }
 
     auto sensorPath =
-        fmt::format("/xyz/openbmc_project/sensors/power/ps{}_input_power_peak",
+        std::format("/xyz/openbmc_project/sensors/power/ps{}_input_power_peak",
                     shortName.back());
 
     peakInputPowerSensor = std::make_unique<PowerSensorObject>(
@@ -1152,7 +1151,7 @@
     if (data.size() != recordSize)
     {
         log<level::DEBUG>(
-            fmt::format("Input history command returned {} bytes instead of 5",
+            std::format("Input history command returned {} bytes instead of 5",
                         data.size())
                 .c_str());
         peakInputPowerSensor->value(std::numeric_limits<double>::quiet_NaN());
@@ -1207,7 +1206,7 @@
         catch (const std::exception& e)
         {
             log<level::ERR>(
-                fmt::format("{} READ_VIN read error: {}", shortName, e.what())
+                std::format("{} READ_VIN read error: {}", shortName, e.what())
                     .c_str());
         }
     }
@@ -1249,7 +1248,7 @@
 
     if (!inputVoltageRatingIface)
     {
-        auto path = fmt::format(
+        auto path = std::format(
             "/xyz/openbmc_project/sensors/voltage/ps{}_input_voltage_rating",
             shortName.back());
 
@@ -1286,7 +1285,7 @@
     catch (const sdbusplus::exception_t& e)
     {
         log<level::ERR>(
-            fmt::format("Failed getProperty error: {}", e.what()).c_str());
+            std::format("Failed getProperty error: {}", e.what()).c_str());
     }
 }
 
diff --git a/phosphor-power-supply/psu_manager.cpp b/phosphor-power-supply/psu_manager.cpp
index 2832959..32da768 100644
--- a/phosphor-power-supply/psu_manager.cpp
+++ b/phosphor-power-supply/psu_manager.cpp
@@ -4,13 +4,13 @@
 
 #include "utility.hpp"
 
-#include <fmt/format.h>
 #include <sys/types.h>
 #include <unistd.h>
 
 #include <xyz/openbmc_project/State/Chassis/server.hpp>
 
 #include <algorithm>
+#include <format>
 #include <regex>
 #include <set>
 
@@ -125,7 +125,7 @@
     catch (const std::exception& e)
     {
         log<level::INFO>(
-            fmt::format(
+            std::format(
                 "Failed to get power state, assuming it is off, error {}",
                 e.what())
                 .c_str());
@@ -140,7 +140,7 @@
     setPowerConfigGPIO();
 
     log<level::INFO>(
-        fmt::format("initialize: power on: {}, power fault occurring: {}",
+        std::format("initialize: power on: {}, power fault occurring: {}",
                     powerOn, powerFaultOccurring)
             .c_str());
 }
@@ -177,7 +177,7 @@
     {
         // Interface or properties not found. Let the Interfaces Added callback
         // process the information once the interfaces are added to D-Bus.
-        log<level::INFO>(fmt::format("No power supplies to monitor").c_str());
+        log<level::INFO>(std::format("No power supplies to monitor").c_str());
     }
 }
 
@@ -225,7 +225,7 @@
         invpath.push_back(psuname->back());
         std::string presline = "";
 
-        log<level::DEBUG>(fmt::format("Inventory Path: {}", invpath).c_str());
+        log<level::DEBUG>(std::format("Inventory Path: {}", invpath).c_str());
 
         if (nullptr != preslineptr)
         {
@@ -249,7 +249,7 @@
 
         buildDriverName(*i2cbus, *i2caddr);
         log<level::DEBUG>(
-            fmt::format("make PowerSupply bus: {} addr: {} presline: {}",
+            std::format("make PowerSupply bus: {} addr: {} presline: {}",
                         *i2cbus, *i2caddr, presline)
                 .c_str());
         auto psu = std::make_unique<PowerSupply>(
@@ -270,7 +270,7 @@
 
     if (psus.empty())
     {
-        log<level::INFO>(fmt::format("No power supplies to monitor").c_str());
+        log<level::INFO>(std::format("No power supplies to monitor").c_str());
     }
     else
     {
@@ -394,7 +394,7 @@
         if (itIntf != interfaces.cend())
         {
             log<level::INFO>(
-                fmt::format("InterfacesAdded for: {}", IBMCFFPSInterface)
+                std::format("InterfacesAdded for: {}", IBMCFFPSInterface)
                     .c_str());
             getPSUProperties(itIntf->second);
             updateMissingPSUs();
@@ -461,7 +461,7 @@
         }
     }
     log<level::INFO>(
-        fmt::format(
+        std::format(
             "powerStateChanged: power on: {}, power fault occurring: {}",
             powerOn, powerFaultOccurring)
             .c_str());
@@ -502,7 +502,7 @@
     catch (const std::exception& e)
     {
         log<level::INFO>(
-            fmt::format("Failed calling setPowerSupplyError due to error {}",
+            std::format("Failed calling setPowerSupplyError due to error {}",
                         e.what())
                 .c_str());
     }
@@ -541,7 +541,7 @@
     catch (const std::exception& e)
     {
         log<level::ERR>(
-            fmt::format(
+            std::format(
                 "Failed creating event log for fault {} due to error {}",
                 faultName, e.what())
                 .c_str());
@@ -629,8 +629,8 @@
                 // Add STATUS_WORD and STATUS_MFR last response, in padded
                 // hexadecimal format.
                 additionalData["STATUS_WORD"] =
-                    fmt::format("{:#04x}", psu->getStatusWord());
-                additionalData["STATUS_MFR"] = fmt::format("{:#02x}",
+                    std::format("{:#04x}", psu->getStatusWord());
+                additionalData["STATUS_MFR"] = std::format("{:#02x}",
                                                            psu->getMFRFault());
                 // If there are faults being reported, they possibly could be
                 // related to a bug in the firmware version running on the power
@@ -640,7 +640,7 @@
                 if (psu->hasCommFault())
                 {
                     additionalData["STATUS_CML"] =
-                        fmt::format("{:#02x}", psu->getStatusCML());
+                        std::format("{:#02x}", psu->getStatusCML());
                     /* Attempts to communicate with the power supply have
                      * reached there limit. Create an error. */
                     additionalData["CALLOUT_DEVICE_PATH"] =
@@ -656,7 +656,7 @@
                 {
                     // Include STATUS_INPUT for input faults.
                     additionalData["STATUS_INPUT"] =
-                        fmt::format("{:#02x}", psu->getStatusInput());
+                        std::format("{:#02x}", psu->getStatusInput());
 
                     /* The power supply location might be needed if the input
                      * fault is due to a problem with the power supply itself.
@@ -682,7 +682,7 @@
                 {
                     // Include STATUS_VOUT for Vout faults.
                     additionalData["STATUS_VOUT"] =
-                        fmt::format("{:#02x}", psu->getStatusVout());
+                        std::format("{:#02x}", psu->getStatusVout());
 
                     additionalData["CALLOUT_INVENTORY_PATH"] =
                         psu->getInventoryPath();
@@ -697,7 +697,7 @@
                 {
                     // Include STATUS_IOUT for Iout faults.
                     additionalData["STATUS_IOUT"] =
-                        fmt::format("{:#02x}", psu->getStatusIout());
+                        std::format("{:#02x}", psu->getStatusIout());
 
                     createError(
                         "xyz.openbmc_project.Power.PowerSupply.Error.IoutOCFault",
@@ -710,7 +710,7 @@
                 {
                     // Include STATUS_VOUT for Vout faults.
                     additionalData["STATUS_VOUT"] =
-                        fmt::format("{:#02x}", psu->getStatusVout());
+                        std::format("{:#02x}", psu->getStatusVout());
 
                     additionalData["CALLOUT_INVENTORY_PATH"] =
                         psu->getInventoryPath();
@@ -728,9 +728,9 @@
                 {
                     // Include STATUS_TEMPERATURE and STATUS_FANS_1_2
                     additionalData["STATUS_TEMPERATURE"] =
-                        fmt::format("{:#02x}", psu->getStatusTemperature());
+                        std::format("{:#02x}", psu->getStatusTemperature());
                     additionalData["STATUS_FANS_1_2"] =
-                        fmt::format("{:#02x}", psu->getStatusFans12());
+                        std::format("{:#02x}", psu->getStatusFans12());
 
                     additionalData["CALLOUT_INVENTORY_PATH"] =
                         psu->getInventoryPath();
@@ -745,7 +745,7 @@
                 {
                     // Include STATUS_TEMPERATURE for temperature faults.
                     additionalData["STATUS_TEMPERATURE"] =
-                        fmt::format("{:#02x}", psu->getStatusTemperature());
+                        std::format("{:#02x}", psu->getStatusTemperature());
 
                     additionalData["CALLOUT_INVENTORY_PATH"] =
                         psu->getInventoryPath();
@@ -842,7 +842,7 @@
         additionalData.emplace("PGOOD_FAULT_COUNT",
                                std::to_string(pgoodFailedCount));
         log<level::INFO>(
-            fmt::format(
+            std::format(
                 "Brownout detected, not present count: {}, AC fault count {}, pgood fault count: {}",
                 notPresentCount, acFailedCount, pgoodFailedCount)
                 .c_str());
@@ -877,7 +877,7 @@
                     // condition by setting the PowerSystemInputs status
                     // property to Good.
                     log<level::INFO>(
-                        fmt::format(
+                        std::format(
                             "Brownout cleared, not present count: {}, AC fault count {}, pgood fault count: {}",
                             notPresentCount, acFailedCount, pgoodFailedCount)
                             .c_str());
@@ -890,7 +890,7 @@
             catch (const std::exception& e)
             {
                 log<level::ERR>(
-                    fmt::format("Error trying to clear brownout, error: {}",
+                    std::format("Error trying to clear brownout, error: {}",
                                 e.what())
                         .c_str());
             }
@@ -940,7 +940,7 @@
                 // Relying on property change or interface added to retry.
                 // Log an informational trace to the journal.
                 log<level::INFO>(
-                    fmt::format("D-Bus property {} access failure exception",
+                    std::format("D-Bus property {} access failure exception",
                                 psuInventoryPath)
                         .c_str());
             }
@@ -1324,7 +1324,7 @@
     }
     catch (const std::exception& e)
     {
-        log<level::ERR>(fmt::format("Failed to find device driver {}, error {}",
+        log<level::ERR>(std::format("Failed to find device driver {}, error {}",
                                     symLinkPath, e.what())
                             .c_str());
     }
diff --git a/phosphor-power-supply/util.cpp b/phosphor-power-supply/util.cpp
index 503e1c3..d1253da 100644
--- a/phosphor-power-supply/util.cpp
+++ b/phosphor-power-supply/util.cpp
@@ -62,7 +62,7 @@
         catch (const std::exception& e)
         {
             log<level::ERR>(
-                fmt::format("Failed to get_value of GPIO line: {}", e.what())
+                std::format("Failed to get_value of GPIO line: {}", e.what())
                     .c_str());
             line.release();
             throw;
diff --git a/phosphor-power-supply/util.hpp b/phosphor-power-supply/util.hpp
index 22e192e..293d44d 100644
--- a/phosphor-power-supply/util.hpp
+++ b/phosphor-power-supply/util.hpp
@@ -3,8 +3,6 @@
 #include "utility.hpp"
 #include "xyz/openbmc_project/Common/error.hpp"
 
-#include <fmt/format.h>
-
 #include <gpiod.hpp>
 #include <phosphor-logging/elog-errors.hpp>
 #include <phosphor-logging/elog.hpp>
@@ -12,6 +10,7 @@
 
 #include <bitset>
 #include <chrono>
+#include <format>
 
 namespace phosphor::power::psu
 {
@@ -43,7 +42,7 @@
                      bool present, const std::string& name) const override
     {
         using namespace phosphor::logging;
-        log<level::INFO>(fmt::format("Updating inventory present property. "
+        log<level::INFO>(std::format("Updating inventory present property. "
                                      "present:{} invpath:{} name:{}",
                                      present, invpath, name)
                              .c_str());
@@ -81,7 +80,7 @@
         catch (const std::exception& e)
         {
             log<level::ERR>(
-                fmt::format(
+                std::format(
                     "Error in inventory manager call to update inventory: {}",
                     e.what())
                     .c_str());
@@ -116,7 +115,7 @@
         {
             using namespace phosphor::logging;
             log<level::ERR>(
-                fmt::format("Error in inventory manager call to update "
+                std::format("Error in inventory manager call to update "
                             "availability interface: {}",
                             e.what())
                     .c_str());
@@ -188,7 +187,7 @@
         catch (const sdbusplus::exception_t& e)
         {
             using namespace phosphor::logging;
-            log<level::INFO>(fmt::format("Error trying to handle health rollup "
+            log<level::INFO>(std::format("Error trying to handle health rollup "
                                          "associations for {}: {}",
                                          invpath, e.what())
                                  .c_str());
@@ -209,7 +208,7 @@
 
         if (chassisPaths.empty())
         {
-            throw std::runtime_error(fmt::format(
+            throw std::runtime_error(std::format(
                 "No association to a chassis found for {}", invpath));
         }
 
