Incorporation of black soldier fly larvae (BSFL) in fecal sludge management shows promise as a resource recovery strategy. BSFL efficiently convert organic waste into valuable lipids and protein, which can be further processed into commercial products. Ensuring the microbial safety of waste-derived products is critical to the success of resource-oriented sanitation and requires the development of effective sludge treatment. This study evaluates the microbial treatment efficacy of the viscous heater (VH) for fecal sludge management and potential application of the VH in BSFL production. The VH is a heat-based fecal sludge treatment technology that harnesses the viscosity of fecal sludge to achieve pasteurization temperatures. Inactivation of in situ Escherichia coli, total coliform, heterotrophic bacteria, and somatic coliphage was evaluated in fecal sludge that was treated for 1-6 min at VH temperature set-points of 60°C and 80°C. The VH inactivated in situ E. coli, total coliform, and somatic coliphage in fecal sludge to below the limits of detection (1- to 5-log10 inactivation) when operated at the 80°C set-point with a 1-min residence time. Both temperature set-points achieved 1- to 3-log10 inactivation of in situ heterotrophic bacteria. The VH was also evaluated as a potential pretreatment step in BSFL production. BSFL grown in untreated and VH-treated fecal sludge demonstrated similar results, indicating little impact on the BSFL growth potential by VH-treatment. However, BSFL bioconversion rates were low for both substrates (1.6% ± 0.6% for untreated sludge and 2.1 ± 0.4 VH-treated fecal sludge).