As stated on his MyAnimeList page:
Calcifer is a fallen star who was caught by Howl. He didn't want to
die, so he struck a deal with the wizard. Calcifer got Howl's heart
and a prolonged life, and Howl received full access to all of
Calcifer's considerable powers.
As it turns out, neither of them liked it after a while, but it
couldn't be broken by people who were part of the contract. When
Sophie Hatter comes to Howl's moving castle, Calcifer recognizes that
she is under a curse thanks to the Witch of Waste and that Sophie has
considerable powers of her own of which she is unaware. To break his
own curse, Calcifer offers to lift the curse placed on Sophie once she
manages to break Calcifer's contract with Howl.
Clacifer is also bound to the hearth, and cannot leave it because of the contract. He also can not explicitly talk about the contract, so he instead gives Sophie hints about it when she agrees to help him break the contract.