In most cases this is caused by wrong start GCODE in your printer profile advanced settings. You can access it via Dashboard -> Printer Profiles -> Printer Name -> Edit -> Advanced Printer Settings
If we focus on the Cura slicer, let's see what can go wrong.
The following example would be wrong Start GCODE:
M104 S[temperature] ; set the extruder temp and wait M140 S[bed_temperature] G28 ; home all axes M190 S[temperature] ; set the extruder temp and wait M109 S[temperature] G80 ; Probe G1 Z5 F5000 ; lift nozzle
The above case shows that both the names of the variables (temperature and bed_temperature) are wrong as well as the enclosing [] symbols.
The following would be correct Start GCODE:
M104 S{print_temperature} ; set the extruder temp and wait M140 S{print_bed_temperature} G28 ; home all axes M190 S{print_bed_temperature} ; set the extruder temp and wait M109 S{print_temperature} G80 ; Probe G1 Z5 F5000 ; lift nozzle
What is happening is that the GCODE variables are not translated into values in the wrong case. When this is sent to the printer, it literally gets "M104 S[temperature]" which is something it doesn't understand and ignores the command, resulting in not starting or keeping the heating component on.