Hepatic ischemia reperfusion (I/R) injury is very common in liver transplantation and major liver surgeries and may cause liver failure or even death. Docosahexaenoic acid (DHA) has displayed activities in reducing oxidative stress and inflammatory reaction in many disorders. In the present study, we investigated the protective effects of DHA against I/R-induced injury and the underlying mechanisms. Here, we show that DHA protected hepatic I/R injury by reducing aspartate aminotransferase (AST) and alanine aminotransferase (ALT) levels and decreasing the oxidative stress in liver tissues. The viability of Buffalo rat liver (BRL) cells was reduced by hypoxia/restoration (H/R) but restored by DHA. DHA significantly downregulated the expression of pyroptosis-related proteins including NLR pyrin domain containing 3 (NLRP3), apoptotic speck-like protein containing CARD (ASC) and cleaved caspase-1 and reduced the secretion of pro-inflammatory cytokines. The above results were supported by terminal deoxynucleotidyl transferase dUTP nick end labeling (TUNEL) staining. However, incubation with LY294002, a specific inhibitor of phosphatidylinositol-3-kinase (PI3K), abolished the effects of DHA, since it increased the expression of cleaved caspase-1 and the production of inflammatory cytokines. The present results have demonstrated that DHA ameliorated I/R-induced injury by inhibiting pyroptosis of hepatocytes induced in liver I/R injury in vivo and in vitro through the PI3K/Akt pathway, providing a potential therapeutic option to prevent liver injury by I/R.