The controllable phosphorylations of thioesters were developed. When the reaction was catalyzed by a palladium catalyst, aryl or alkenyl phosphoryl compounds were generated through decarbonylative coupling, while the benzyl phosphoryl compounds were produced through deoxygenative coupling when the reaction was carried out in the presence of only a base.