A pill container is disclosed. The pill container is separably disposed in an electronic pill box. The pill container includes an accommodating portion and a cover portion. The accommodating portion has a pill accommodating space. The cover portion is movably connected to the accommodating portion and has a barcode. When the pill container is disposed in the electronic pill box, the barcode is readable.一種藥物容器,其係可分離地容置於一電子藥盒,藥物容器包括一容置部以及一開闔部。容置部具有一藥物容置空間。開闔部可動地連接於容置部,且開闔部具有一條碼,當藥物容器容置於電子藥盒時,條碼係為可讀取。121‧‧‧條碼122‧‧‧連接件2‧‧‧輔助服藥裝置21‧‧‧藥物容器22‧‧‧電子藥盒221‧‧‧基座222‧‧‧收容單元223‧‧‧上蓋部224‧‧‧磁吸件225‧‧‧警示元件227‧‧‧開闔感測單元23‧‧‧攝影模組24‧‧‧處理模組25‧‧‧提示模組251‧‧‧顯示面板26‧‧‧控制模組27‧‧‧輸入模組P1、P2‧‧‧開口S‧‧‧容置空間