LAD Media, which provides financial data, must pay £50,000 after messages about debt relief schemes triggered more than 150 complaints.
The law says marketing texts can only be sent with the recipient's consent.
The Information Commissioner's Office said the firm "did not comply with the law". LAD Media said the messages were sent on its behalf by another company.
According to the law, organisations buying data for marketing - or those who commission other firms to carry out marketing for them - must still ensure they comply with the law.
This means checking that personal details have been obtained fairly and lawfully, and that the people have given the necessary consent to receive the texts.
The firm, based in Bury, Greater Manchester, said it obtained people's details from a third-party data supplier.
A firm that sent nearly 400,000 unsolicited spam texts has been fined.