The first step is to assess the actual level of risk. Not every similar trademark is a direct obstacle; the relevant factors are how similar the marks are, how closely related the goods and services are, and which jurisdiction the conflicting mark is registered in. A trademark attorney can give you a professional view on whether the similarity is likely to cause a problem.
If the risk is real, the options include approaching the owner to negotiate a co-existence agreement, adjusting your mark to increase the distance between the two, limiting the goods and services in your application to avoid the classes where the conflict arises, or rebranding before you invest further in the current mark.
If you proceed with filing and the owner of the earlier mark opposes your application, the proceedings can be resolved by agreement, by demonstrating that the marks are not in fact confusingly similar, or in some cases by challenging the validity of the earlier mark itself.
Get a professional risk assessment before deciding with a free lawyer's check.