There is a significant benefit in gifting stock in-kind rather than selling it and contributing the net proceeds. You avoid paying any tax due on the sale of the stock and if the charity sells the stock there is no tax since the charity is a tax-exempt entity.
If the donation helps you itemize and you’re trying to offset windfall gains in the same year (e.g. the sale of your business), then all the better. Keep an eye on the rule that the current year deduction involving appreciated securities is limited to 30% of your adjusted gross income, but the excess can be carried forward to a future year.