In this article, we present a fully higher-order compact (FHOC) finite difference method to investigate the effects of heat flux on natural convection of nanofluids in a right-angle triangle cavity, where the left vertical side is heated with constant heat flux both partially and throughout the entire wall, the inclined wall is cooled, and the rest of walls are kept adiabatic. The Darcy flow and the Tiwari and Das' nanofluid models are considered. Investigations with four types of nanofluids were made for different values of Rayleigh numbers with the range of 100 ≤ Ra ≤ 50,000, size of heat flux as 0.1 ≤ ≤ 1.0, enclosure aspect ratio as 0.5 ≤ AR ≤ 2.0, and solid volume fraction parameter of nanofluids with the range of 0% ≤ ≤ 20%. Results show that the average heat transfer rate increases significantly as particle volume fraction and Rayleigh numbers increase, and the maximum value of average Nusselt number is obtained by decreasing the enclosure aspect ratio. The results also show that the average heat transfer decreases with an increase in the length of the heater. Furthermore, multiple correlations in terms of the Rayleigh numbers and the solid volume fraction of four types of nanoparticles have been established in a general form. C⃝ 2016 Wiley Periodicals, Inc. Heat Trans Asian Res, 46 (7): 761-777, 2017; Published online in Wiley Online Library (wileyonlinelibrary.com/journal/htj).