PurposeThe purpose of this paper is to investigate the relationship between tax avoidance and the cost of debt and the moderating roles of financial constraints and information asymmetry. It also examines a potential nonlinear effect of tax avoidance on the cost of debt.Design/methodology/approachThe sample covers 3,732 firm-year observations in France from 2009 to 2020. This paper uses Prais-Winsten and ordinary least squares regressions to examine the effect of tax avoidance on the cost of debt.FindingsThe results show a negative effect of corporate tax avoidance on the cost of debt, suggesting that companies using tax avoidance strategies tend to incur lower borrowing costs. Furthermore, the results reveal a U-shaped relationship between tax avoidance and the cost of debt. However, beyond a threshold, aggressive tax practices, coupled with increased information asymmetry, result in a positive association between tax avoidance and the cost of debt. The results also show that the negative effect of tax avoidance on the cost of debt is more prevalent when firms are less financially constrained and incur low levels of information asymmetry.Research limitations/implicationsOne of the limitations of this study is that the results are based on a single country. The results might not be generalizable to other institutional settings.Practical implicationsWhile tax avoidance can help reduce the cost of debt, it is crucial for companies to ensure that their tax strategies comply with laws and regulations. Lenders should carefully assess the tax practices of borrowing companies and their information asymmetry to evaluate firm risk and adjust their cost of debt.Originality/valueThis research extends previous studies by investigating the nonlinear association between tax avoidance and the cost of debt. While previous research primarily focused on linear relationships, this study delves into the complexity of the relationship, offering a more comprehensive understanding of how tax avoidance affects the cost of debt.