To personalize email template body and email subject you can use email personalization tags directly inside the email subject line and it will work for the campaigns automatically.

List of all email personalization tags are available here.

For example, you want to get the subject line like this:

[First Name], This is the subject line

Then you can update the subject line like this – inside email template and email campaign:

{contactfield=firstname}, This is the subject line

Above tag, {contactfield=firstname} will automatically resolve into contacts first name inside the sent campaigns.

Note: These email personalization tags might not work inside the test email campaigns.