add item in dict python code example Example: add item to python dictionary data = dict() data['key'] = value