Is it possible to have a phone alarm go off if it moves a set distance away from a NFC tag? I have a bad habit of leaving my phone around. I want my phone to alert me if it gets to far away from me.

If this is possible how can I set this up?
That's not how NFC works. The N stands for "near", and it really means that: the tag has to be touching the back of the phone for it to be read. Sometimes even putting a case on the phone stops it reading NFC tags.

If you want something like this, you could buy a Samsung Galaxy Note 2 or later. These phones have a special feature using the phone's stylus (S Pen), where if the phone gets more than about a metre from the stylus, it will start to bleep. It's mainly intended to stop you forgetting the stylus, but it works just as well the other way around. Some newer Bluetooth headsets, and some Bluetooth LE watches have this feature too: the headset alerts you if it goes out of range of the phone.



Since writing the above, Bluetooth Low Energy has become a lot more widely available, with a lot more peripherals supporting it as well as handsets and apps. One way to achieve the desired goal on any phone with BLE support is with a consumer BLE beacon such as Stick N Find. You can stick the beacon on a keyring (or something else you carry) and use the included app on your phone to alert you when it moves too far away (range configurable up to tens of metres). There are a few similar products such as Tile and Chipolo, but that was the only one I found with the "alert when you walk away" functionality.