Consultants are often asked if they'd be willing to take equity in lieu of cash for their services rendered.
In some cases, this arrangement can be beneficial to both sides. The company can get expertise it needs, without parting with cash, and the consultant has an opportunity to reap the rewards of the upside he or she helped to create.
Consultants need to remember though, that equity is inherently riskier, and that understanding the value of a particular company's equity requires significant due diligence, which takes time away from doing actual consulting work. Consultants are generally not expert investors, and may lack the time and skills to fully assess the value of the equity being offered.
Only take equity if you really know the business, are confident in the investment structure, and are willing to lose the entire amount.