Skip to content
Material design UITextField with animated placeholder label and error message
Branch: master
Clone or download
Latest commit 5c62fa4 Jan 18, 2019
Type Name Latest commit message Commit time
Failed to load latest commit information.
MaterialTextField.xcodeproj Bump min deployment target to iOS 10.0 Jun 24, 2018
MaterialTextField Fix both floating & inline placeholders being shown when text is cleared Jul 15, 2018
MaterialTextFieldDemo Fix textPadding for left & right views Jul 15, 2018
MaterialTextFieldTests Rename project to MaterialTextField Nov 8, 2015
Screenshots Add gif to README Dec 18, 2015
.gitignore Initial commit Jul 21, 2015
LICENSE Create LICENSE Nov 8, 2015
MaterialTextField.podspec Release 1.0.1 Jul 15, 2018 Update README Jan 18, 2019


A Material Design inspired UITextField with animated placeholder label and error message.

MaterialTextField gif


Floating placeholder label
  • Animates on focus or on text input
  • Supports attributed placeholder text with custom fonts
  • Can be turned off to use the text field with the default UITextField placeholder
  • Line height expands when editing
  • Set colours for default, editing and error states
Error message
  • Animated error message appears below the text field
  • Long error messages wrap onto multiple lines
IBDesignable view
  • Adjust the appearance of the text field in Interface Builder with inspectable properties



To install via CocoaPods, add to your podfile:

pod 'MaterialTextField', '~> 1.0'


First, add this to your Cartfile:

github "stephsharp/MaterialTextField"

Then run carthage update.

The recommended way to integrate MaterialTextField.framework is as a workspace dependency:

  1. If you don't yet have a workspace, go to the File menu in Xcode and select Save as Workspace...
  2. At the bottom left of the project navigator, select the + and add Carthage/Checkouts/MaterialTextField/MaterialTextField.xcodeproj.
  3. Add MaterialTextField.framework to your app's "Link Binary with Libraries" build phase.


I found the following libraries to be useful resources:


MaterialTextField is released under the MIT license. See LICENSE for details.

You can’t perform that action at this time.