diff --git a/api/IPAddress.h b/api/IPAddress.h
index 28dde3be..31a2d06d 100644
--- a/api/IPAddress.h
+++ b/api/IPAddress.h
@@ -98,7 +98,7 @@ class IPAddress : public Printable {
     virtual size_t printTo(Print& p) const;
     String toString() const;
 
-    IPType type() { return _type; }
+    IPType type() const { return _type; }
 
     friend class UDP;
     friend class Client;