I use a magnetic sensor on the drive sprocket personally. It allows the wiring to run within the stock Alternator harness for tidiness.
I use a magnetic 6mm bolt in place of the stock bolts, or, you can drill the head of a stock bolt, and epoxy the magnetic to it. The sensor is held off the sprocket from the other side with a small piece of scrap metal welded to the chain cage, then poked thru. Doing this allows simple adjustment of the diameter setting within the speedo menu.