Given these two choices:
- What if a bacterium, with a similar effect on humans to Wolbachia in pillbugs, rapidly spread through our world in the early 21st century?
- What if a bacterium, with a similar effect on humans as Wolbachia shows in pillbugs, rapidly spread through our world in the early 21st century?
Neither is always considered wrong by all speakers. However, version (1) where similar and to are so far separated can sound quite strange to some speakers, especially in those not used to hearing constructions like that. To them it may not necessarily sound grammatical, or sensible, or clear.
As this related question shows, whenever you split similar to up by putting other words between those two, you risk confusing folks. My own preference is therefore to rephrase so as to keep similar to intact with no other words falling between them. That leads to such choices as these, ranging from more verbose to less so:
- What if a bacterium that affected humans similarly to how the Wolbachia bacterium affects pillbugs were to spread rapidly throughout our world in the early 21st century?
- What if a bacterium with an effect in humans that’s similar to the effect that the Wolbachia bacterium has in pillbugs were to spread rapidly throughout our world in the early 21st century?
- What if a bacterium with an effect in humans that’s similar to that of Wolbachia in pillbugs spread rapidly throughout our world in the early 21st century?
- What if a bacterium with an effect in humans that’s similar to Wolbachia’s in pillbugs spread rapidly throughout our world in the early 21st century?
- What if a bacterium with an effect in humans similar to Wolbachia’s in pillbugs spread rapidly throughout our world in the early 21st century?
Any of those is likely to come across as clearer but nonetheless wordier than the original. Personal patience for wordiness will always vary depending on the writer. For example, notice how the last two use a possessive form with -’s to allow skipping the second instance of effect, but that elision may not be as clear to all speakers as spelling it out more explicitly. The more you chop out, the more you risk people getting a misreading, as least on their first or second time through.