store index as number, not bytes