This is a step by step tutorial to help you write, or in the official NFC terminology ‘encode’, your first NFC tags with an Android phone. If you are using an iPhone, then check our tutorial on how to encode NFC tags with an iPhone.
If you prefer to watch a video, then just press play.
NFC Tag encoding options
There are really two options for encoding NFC tags. Either get Seritag to encode your tags for you when you buy them or encode them yourself with a mobile phone.
Encoding tags yourself with a mobile is quick and easy. For small quantities of tags, perhaps up to a hundred or so, it can be no problem. If you are planning a large roll-out of tags and expect to be using many hundreds or thousands of NFC tags, then we’d recommend that we encode for you.
Can NFC Tags be encoded with an iPhone ?
Yes, with the latest iOS13 software and the latest iPhones. With older software such as the iOS11 or an iPhone older than the iPhone 7, then no.
To clear any confusion, the iPhone 7,8, X, Xs and Xr can all read NFC tags with iOS11 or later. Encoding NFC tags is a different process and requires iOS13.
If you are using an iPhone, then check our tutorial on how to encode NFC tags with an iPhone.
Which mobile phones do you recommend to encode NFC Tags ?
In short, almost any Android NFC enabled smartphone. You will need to download an App but the best encoding App is free, reliable and easy to use.
Encoding your tags doesn’t require specialist knowledge or technical skills. You just need to know the web address you want to encode, download the App to your Android phone, tap a few buttons and then wave the phone over your tag. Done.
Which NFC tag to use ?
There’s two answers here.
The first is which NFC chip do you need ? There’s a detailed breakdown of the different NFC chip types on our website but to save you the read, to get started, buy yourself NFC tags with the NTAG213 chip.
Unless you plan on encoding vCard contact details (which Seritag strongly suggest that you don’t), then the NTAG213 chip will do everything you will probably need.
For the format/style of the tag, then start with plain or printed stickers. They are cheap and you can test and start encoding without worry. We’d suggest a set of plain white (or clear) 22mm to 38mm size NTAG213 NFC tags will work just fine.
Step 1. Download the NFC App
There are a large number of NFC Apps available for Android users. However, the App we are going to recommend here is made by NXP, who make the chips that go into the majority of NFC tags you can buy.
It’s reliable, free and comprehensive. Android users can download NXP Tagwriter from Google Play.
Step 2. Get your NFC Tags ready
Most NFC tags will not work on metal surfaces. There are tags that do, which are called ‘on-metal’ tags but normal NFC tags won’t. So, the first thing is to make sure you haven’t put your tag on a metal desk before you try to encode it !
There isn’t a front and back to a normal NFC tag (there is to an on-metal NFC tag). You don’t need to remove the liner if it’s a sticker. Just place one on your desk.
If this is your first time encoding tags then we would suggest cutting or removing a single tag from your reel or strip and use that. This is especially important if the tags are small because some phones have a small ‘hotspot’ on the back of the phone.
If you have multiple small tags on a strip of tags then it can be quite easy to encode the next one rather than the one you were aiming for. It might not make much difference but it can be a little confusing when you are testing things.
Step 3. Open the App and start encoding
Screen 1 : Install and open the App
First, download NXP Tagwriter from Google Play. The App is free to use and reliable. The App will enable you both to read NFC tags and encode NFC tags.
It’s a full featured App but there’s no need to use all the features. On opening the App, you will be presented with an options screen. We are just going to undertake a simple encoding of a web address (URL) – ‘https://seritag.com’. Tap on the ‘Write tags’ square to begin.
Screen 2 : Select your data source
The ‘Write tags’ screen presents you with options related to where to get the data to do your encoding. You can encode from a previous stored dataset, copy data from another tag or QR code or write using data from a CSV (excel spreadsheet) file. For this example, we are going to create a new dataset so tap on the ‘New dataset’ option.
Screen 3 : Select link encoding
Now we have to choose which type of data we are going to encode. The way that data is stored on an NFC tag is defined by certain standards. These require the data type to be defined clearly so that any other device reading the NFC tag can understand what type of data to expect.
In this example, we are going to store a web address ‘https://seritag.com’ which is described in Tagwriter as a ‘Link’. So tap the ‘Link’ option and we can start adding data.
Screen 4 : Add your encoding data
This screen has a number of options but you don’t need to worry about them to do simple web link encoding. In the example here, we’ve added ‘https://seritag.com’ and selected a URI type of URL.
It’s important that you include either http:// or https:// in front of your normal web address. Use https:// if it’s a secure website (you have a padlock on your page) or http:// if it isn’t.
If you aren’t sure, visit the page you want to link to in your browser and then copy and paste the address from the address bar at the top of the browser. Most browsers will copy the full link including https:// or http://. That’s all you need to do and then you can tap ‘Save & Write’. We’ve added details on what all the options do below the image. You don’t need to read these to finish this tutorial.
Additional encoding data options (optional)
There are two basic ways of encoding a web link onto a tag. The first is a ‘Smart Poster’ type which typically stores the link and a title. The second is a URI type which just stores the link.
There’s very little point in storing a title – it’s never* used under normal circumstances. *never means that Seritag have never come across a use case for it ever ! All it does it take up memeory space which, if you are using a smaller tag such as a NTAG210, may mean you run out of space.
In short – don’t add a title.
Technically, a ‘link’ in this instance is not just a web link (generally defined as URL) which works over http(s)://. It can also mean any link protocol including mailto, ftp, etc.
Additionally, it’s possible not to use a preset ‘URI identifier’ definition and enter an entire URI. In most instances, the NFC reader will understand the best it can. Which, in reality, in most cases other than a web address means that you will have no idea how it will react or if it will react at all.
Note that mobile phones will (in all cases Seritag have experienced) understand a web address encoding without a URI identifer. There’s no real harm in encoding like this but you do need 7 or 8 additional memory bytes.
Add Tag UID (mirror)
Each NFC tag has a unique (if the tag is genuine) 7 byte ID hard coded into the memory. It can’t (on a genuine NXP chip) be changed.
Some phones can’t actually scan this as they only can read – or perhaps more accurately present – the ‘user memory’ area. Therefore, in some cases, it makes sense to ‘mirror’ this UID into a URL.
For example, if the UID was AABBCCDD112233 and your URL was https://seritag.com?tag=22, you could mirror the UID onto the URL such as ‘https://seritag.com?tag=22&uid=AABBCCDD112233’.
Add Interaction Counter (mirror)
Most newer NFC chips have an in-built counter which records how many times the tag has been scanned. This can be useful in a number of applications from security to marketing.
The counter is stored in a part of the chip’s memory that some phones can’t readily get to without a specific App – and some phones don’t offer access at all. So, the count can be mirrored dynamically into the URL.
For example, your URL might be ‘https://seritag.com?count=’ and the count will be added to the end. First scan it would be count=1, then on the second scan it would be count=2 and so on.
For developers, remember that this is the number of times the tag has been scanned, not the number of times the user has visited the link. The two are definitely not the same.
Add NTAG213TT Message (mirror)
NXP recently released a new NFC chip called the NTAG213 Tag Tamper or NTAG213 TT. This is a clever little chip which has an extra couple of terminals on the chip.
A loop of wire (separate to the NFC antenna) can be attached and the chip can detect if the loop has been broken at any point. Very clever.
This change in ‘status’ is recorded in the chips memory and can be accessed by a special App or, in the case of selecting this option, can be added to the URL. For example, an unbroken URL might show https://seritag.com?broken=00000000 and a broken/tampered tag will magically change this URL to https://seritag.com?broken=FFFFFFFF.
It’s a quick, simple way for anyone with an NFC phone to detect if a tag has been messed with.
Enable SUN Message
This is complicated and works only with the latest authentication NFC tags such as the NTAG424 and NTAG413. It has a feature whereby each time the tag is tapped it can generate a new unique code – in a similar way to those online banking keycode generators.
This code, ‘Secure Unique NFC’, can be added to a URL automatically each time the tag is scanned. This, essentially, enables a level of App free tag authentication. It’s extremely powerful and probably the best solution yet to open access (App free) NFC tag authentication.
There aren’t that many NTAG413 or NTAG424 tags around at the moment but it’s a very strong step in the right direction. Note that this feature requires specialist technology such as our Ixkio platform to verify the authenticity of the SUN message.
Screen 5 : Confirm encoding options
This screen allows contains some additional options. You can leave all the settings as they are but if you are interested in what they do, we’ve added some notes below the image. To continue, tap on the ‘write’ button.
Write multiple NFC Tags
If you are encoding the same web link onto more than one tag, then this is how to do it. You simply check the ‘write multiple’ option and then you can tap your phone against a sequence of NFC tags and it will encode them all with the same data as the first.
NFC tags contain a ‘lock’ which prevents the data that you encode on the tag being changed. Until you lock a tag, anyone can change the data. After you lock it, nobody can change the data.
There’s three options here but ignore the first ‘soft’ one. The third option is to ‘Lock’ the tag. This will prevent any further changes. If you are messing about and playing with encoding then don’t check this. Once the tag is locked, there’s no going back.
If you are using the tags in a public place, then you really do need to lock. The second option is to password protect. Newer NFC tags have a password protection feature which means that reading and/or writing the data requires a password.
Screen 6 : Place phone over NFC tag
Now simply hold your phone within a few centimeters of your NFC tag. Note that the ‘hotspot’ on the phone is usually near the top but on some older phones it can be somewhere around the middle. If you wave the phone around slowly you will find it and then you will know ! The phone will respond with a sound and/or vibration when it finds the tag.
Screen 7 : Confirm that you want to overwrite
On the previous options screen (Screen 5), we left the ‘confirm overwrite’ option enabled. That’s this screen. If you uncheck that box then you do not need to provide confirmation of the encoding here – it will just go ahead an encode (if it can).
Once you get started, you will uncheck that box pretty quickly. For now, just select ‘tap to confirm store’ holding your phone over the NFC tag.
Screen 8 : Encoding complete
If all has gone well, you should see a ‘Write successful’ page with further information of what has been encoded. That’s it – you have encoded your first NFC tag.
If you now close the App and wave your phone over the NFC tag, your Android phone will (should) automatically launch your link.