Tj max will specify the max junction temp, the device can withstand ... you have to look into the graphs in DS to see what's the allowed rms current at this Tj. That means you may not be able run at max power what you need at this temp of junction. Also, with or without heat sink, you can calculate what can be the ambient temp for the device operation. This is more important from the product function point of view.
Also allow for dust and fluff on the heat sink, that the life of a semiconductor is doubled for every 10 degrees C BELOW Tj max and you don't want people to burn them selves on the heat sink.
Frank
As mentioned earlier, the power handling capacity for the triac at max junction temp will not be higher. It will be very less. Share the triac part DS so that we can look into the P vs jn temp graph. This can suggest what can be the max jn temp for handling 500W power.
Just for example, if for 500W power dissipation, the allowed max jn temp is 110C, then you have work backwards from here for heat sink Rth calculation. Take a safety margin for device jn operation and also for the heat sink Rth.
Actually, 20K/W is heatsink to ambient, add 3K/W for junction to case and 1.4K/W case to heatsink, and you will have 24.4K/W junction to ambient.
24.4C/W*3.07W = 75°C rise.
If maximum junction temperature is 125°C, then maximum ambient temperature is 125-75=50°C.